Skip to content

Commit 3cfaeac

Browse files
committed
fixed: CGL
1 parent ba36b0a commit 3cfaeac

File tree

1 file changed

+18
-18
lines changed

1 file changed

+18
-18
lines changed

ui/jquery.ui.selectmenu.js

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -28,13 +28,13 @@ $.widget("ui.selectmenu", {
2828

2929
_create: function() {
3030
var self = this, o = this.options;
31-
31+
3232
// make / set unique id
3333
var selectmenuId = this.element.uniqueId().attr( "id" );
3434

3535
// quick array of button and menu id's
3636
this.ids = [ selectmenuId, selectmenuId + '-button', selectmenuId + '-menu' ];
37-
37+
3838
// define safe mouseup for future toggling
3939
this._safemouseup = true;
4040
this.isOpen = false;
@@ -714,37 +714,37 @@ $.widget("ui.selectmenu", {
714714
},
715715

716716
disable: function( index, type ){
717-
// if options is not provided, call the parents disable function
718-
if ( typeof( index ) == 'undefined' ) {
719-
this._setOption( 'disabled', true );
720-
} else {
721-
this._toggleEnabled( ( type || "option" ), index, false );
722-
}
717+
// if options is not provided, call the parents disable function
718+
if ( typeof( index ) == 'undefined' ) {
719+
this._setOption( 'disabled', true );
720+
} else {
721+
this._toggleEnabled( ( type || "option" ), index, false );
722+
}
723723
},
724724

725725
enable: function( index, type ) {
726-
// if options is not provided, call the parents enable function
727-
if ( typeof( index ) == 'undefined' ) {
728-
this._setOption( 'disabled', false );
729-
} else {
730-
this._toggleEnabled( ( type || "option" ), index, true );
731-
}
726+
// if options is not provided, call the parents enable function
727+
if ( typeof( index ) == 'undefined' ) {
728+
this._setOption( 'disabled', false );
729+
} else {
730+
this._toggleEnabled( ( type || "option" ), index, true );
731+
}
732732
},
733733

734734
_disabled: function( elem ) {
735-
return $( elem ).hasClass( 'ui-state-disabled' );
735+
return $( elem ).hasClass( 'ui-state-disabled' );
736736
},
737-
737+
738738
// true = enabled, false = disabled
739739
_toggleEnabled: function( type, index, flag ) {
740740
var element = this.element.find( type ).eq( index ),
741741
elements = ( type === "optgroup" ) ? this.list.find( 'li.ui-selectmenu-group-' + index ) : this._optionLis.eq( index );
742-
742+
743743
if ( elements ) {
744744
elements
745745
.toggleClass( 'ui-state-disabled', !flag )
746746
.attr( "aria-disabled", !flag );
747-
747+
748748
if ( flag ) {
749749
element.removeAttr( "disabled" );
750750
} else {

0 commit comments

Comments
 (0)