1
0
mirror of synced 2024-11-26 23:06:02 +03:00

fixed dropdown positioning when select2 has margins. fixes #501

This commit is contained in:
Igor Vaynberg 2012-10-16 10:22:25 -07:00
parent 258a85b06c
commit 3ed91862fa

View File

@ -883,9 +883,9 @@ the specific language governing permissions and limitations under the Apache Lic
// abstract // abstract
positionDropdown: function() { positionDropdown: function() {
var offset = this.container.offset(), var offset = this.container.offset(),
height = this.container.outerHeight(true), height = this.container.outerHeight(false),
width = this.container.outerWidth(true), width = this.container.outerWidth(false),
dropHeight = this.dropdown.outerHeight(true), dropHeight = this.dropdown.outerHeight(false),
viewportBottom = $(window).scrollTop() + document.documentElement.clientHeight, viewportBottom = $(window).scrollTop() + document.documentElement.clientHeight,
dropTop = offset.top + height, dropTop = offset.top + height,
dropLeft = offset.left, dropLeft = offset.left,