Selectmenu: Do not remove ui-state-focus class on first button focus (follow-up)

This commit is contained in:
Felix Nagel 2012-10-27 20:49:35 +02:00
parent b6e1c86864
commit 684b55bcbc

View File

@ -303,8 +303,9 @@ $.widget( "ui.selectmenu", {
focus: function( event ) { focus: function( event ) {
// init Menu on first focus // init Menu on first focus
this.refresh(); this.refresh();
// reset focus class as its removed by ui.widget._setOption
this.button.addClass( "ui-state-focus" );
this._off( this.button, "focus" ); this._off( this.button, "focus" );
event.preventDefault();
}, },
click: function( event ) { click: function( event ) {
this._toggle( event ); this._toggle( event );