File tree Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Original file line number Diff line number Diff line change 34
34
checkAllText : 'Check all' ,
35
35
uncheckAllText : 'Uncheck all' ,
36
36
noneSelectedText : 'Select options' ,
37
+ showCheckAll : true ,
38
+ showUncheckAll : true ,
37
39
selectedText : '# selected' ,
38
40
selectedList : 0 ,
39
41
closeIcon : 'ui-icon-circle-close' ,
83
85
. addClass ( 'ui-helper-reset' )
84
86
. html ( function ( ) {
85
87
if ( o . header === true ) {
86
- return '<li><a class="ui-multiselect-all" href="#"><span class="ui-icon ui-icon-check"></span><span>' + o . checkAllText + '</span></a></li><li><a class="ui-multiselect-none" href="#"><span class="ui-icon ui-icon-closethick"></span><span>' + o . uncheckAllText + '</span></a></li>' ;
88
+ var header_lis = '' ;
89
+ if ( o . showCheckAll )
90
+ header_lis = '<li><a class="ui-multiselect-all" href="#"><span class="ui-icon ui-icon-check"></span><span>' + o . checkAllText + '</span></a></li>' ;
91
+ if ( o . showUncheckAll )
92
+ header_lis += '<li><a class="ui-multiselect-none" href="#"><span class="ui-icon ui-icon-closethick"></span><span>' + o . uncheckAllText + '</span></a></li>' ;
93
+ return header_lis ;
87
94
} else if ( typeof o . header === "string" ) {
88
95
return '<li>' + o . header + '</li>' ;
89
96
} else {
356
363
}
357
364
} )
358
365
. delegate ( 'label' , 'keydown.multiselect' , function ( e ) {
366
+ if ( e . which === 82 )
367
+ return ; //"r" key, often used for reload.
368
+ if ( e . which > 111 && e . which < 124 )
369
+ return ; //Keyboard function keys.
359
370
e . preventDefault ( ) ;
360
-
361
371
switch ( e . which ) {
362
372
case 9 : // tab
363
373
case 27 : // esc
You can’t perform that action at this time.
0 commit comments