]> source.dussan.org Git - jquery-ui.git/commitdiff
added: option appendTo (where to append menu element), thx @payahnih, see #155
authorFelix Nagel <info@felixnagel.com>
Wed, 18 Jan 2012 00:30:01 +0000 (01:30 +0100)
committerFelix Nagel <info@felixnagel.com>
Wed, 18 Jan 2012 00:30:01 +0000 (01:30 +0100)
ui/jquery.ui.selectmenu.js

index cc75ce87e83ed01ccc56ce9772bfe3c680e8ba42..811c875850ef7fab7db64d444c49e518a8da5300 100644 (file)
@@ -17,6 +17,7 @@ $.widget("ui.selectmenu", {
        eventPrefix: "selectmenu",
        options: {
                transferClasses: true,
+               appendTo: "body",
                typeAhead: 1000,
                style: 'dropdown',
                positionOptions: {
@@ -203,7 +204,7 @@ $.widget("ui.selectmenu", {
                });
                this.listWrap = $( "<div />", {
                        'class': self.widgetBaseClass + '-menu'
-               }).append( this.list ).appendTo( 'body' );
+               }).append( this.list ).appendTo( o.appendTo );
                
                // transfer menu click to menu button
                this.list