Skip to content

Commit

Permalink
Merge remote branch 'kborchers/menu_focus'
Browse files Browse the repository at this point in the history
  • Loading branch information
jzaefferer committed Jul 27, 2011
2 parents da7f419 + e16e99a commit 0ba493d
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions ui/jquery.ui.menu.js
Expand Up @@ -71,6 +71,18 @@ $.widget( "ui.menu", {
if ( target.length ) {
self.blur( event );
}
})
.bind( "focus.menu", function( event ) {
if ( self.options.disabled ) {
return;
}
self.focus( event, $( event.target ).children( ".ui-menu-item:first" ) );
})
.bind( "blur.menu", function( event ) {
if ( self.options.disabled ) {
return;
}
self.collapseAll( event );
});
this.refresh();

Expand Down

0 comments on commit 0ba493d

Please sign in to comment.