Skip to content

Commit 3378031

Browse files
committed
Merge pull request #567 from DarkAvanger/master
Added option for setting custom menu width
2 parents 5bbfe5a + 84391ff commit 3378031

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/jquery.multiselect.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,8 @@
4141
autoOpen: false,
4242
multiple: true,
4343
position: {},
44-
appendTo: "body"
44+
appendTo: "body",
45+
menuWidth:null
4546
},
4647

4748
_create: function() {
@@ -444,7 +445,7 @@
444445
// set menu width
445446
_setMenuWidth: function() {
446447
var m = this.menu;
447-
m.outerWidth(this.button.outerWidth());
448+
m.outerWidth(this.options.menuWidth || this.button.outerWidth());
448449
},
449450

450451
// move up or down within the menu

0 commit comments

Comments
 (0)