From e217c402875153ea74a26c266bb36665f82b1cbb Mon Sep 17 00:00:00 2001 From: Felix Nagel Date: Thu, 11 Jul 2013 00:45:54 +0200 Subject: [PATCH] Selectmenu: introduce _position method for easier extending --- ui/jquery.ui.selectmenu.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/ui/jquery.ui.selectmenu.js b/ui/jquery.ui.selectmenu.js index f9ece9c02..2b9f41547 100644 --- a/ui/jquery.ui.selectmenu.js +++ b/ui/jquery.ui.selectmenu.js @@ -192,12 +192,16 @@ $.widget( "ui.selectmenu", { this.isOpen = true; this._toggleAttr(); - this.menuWrap.position( $.extend( { of: this.button }, this.options.position ) ); + this._position(); this._on( this.document, this._documentClick ); this._trigger( "open", event ); }, + + _position: function() { + this.menuWrap.position( $.extend( { of: this.button }, this.options.position ) ); + }, close: function( event ) { if ( !this.isOpen ) { -- 2.39.5