Selectmenu: fire focus event when menu is opened

This commit is contained in:
Felix Nagel
2013-05-30 21:05:48 +02:00
parent a572f72dde
commit dfbd712d99

View File

@@ -133,7 +133,7 @@ $.widget( "ui.selectmenu", {
var item = ui.item.data( "ui-selectmenu-item" );
// prevent inital focus from firing and checks if its a newly focused item
if ( !that.isOpen && that.focusIndex !== undefined && item.index !== that.focusIndex ) {
if ( that.focusIndex !== undefined && item.index !== that.focusIndex ) {
that._trigger( "focus", event, { item: item } );
if ( !that.isOpen ) {
that._select( item, event );