Skip to content
Permalink
Browse files

Menubar: Handle cursor UP/DOWN to open menu

  • Loading branch information
jzaefferer committed Mar 17, 2011
1 parent 2e38e04 commit 37fee24ea60925b9d81251b5c734cb6c40465949
Showing with 9 additions and 0 deletions.
  1. +9 −0 tests/visual/menu/menubar.js
@@ -62,6 +62,15 @@ $.widget("ui.menubar", {
self._open(event, menu);
}
})
.bind( "keydown", function( event ) {
switch ( event.keyCode ) {
case $.ui.keyCode.UP:
case $.ui.keyCode.DOWN:
self._open( event, $( this ).next() );
event.preventDefault();
break;
}
})
.addClass("ui-button ui-widget ui-button-text-only ui-menubar-link")
.wrapInner("<span class='ui-button-text'></span>");

0 comments on commit 37fee24

Please sign in to comment.
You can’t perform that action at this time.