From: kborchers Date: Fri, 13 Jul 2012 04:01:13 +0000 (-0500) Subject: Menu: Fix issue with missing active item when clicking a menu item more than once X-Git-Tag: 1.9.0-rc.1~47 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=be0be892d3a2658f1f4518a7d3346ef356aa89c6;p=jquery-ui.git Menu: Fix issue with missing active item when clicking a menu item more than once --- diff --git a/ui/jquery.ui.menu.js b/ui/jquery.ui.menu.js index e8b8ed1fc..be04fff1c 100644 --- a/ui/jquery.ui.menu.js +++ b/ui/jquery.ui.menu.js @@ -583,7 +583,8 @@ $.widget( "ui.menu", { select: function( event ) { // Save active reference before collapseAll triggers blur var ui = { - item: this.active + // Selecting a menu item removes the active item causing multiple clicks to be missing an item + item: this.active || $( event.target ).closest( ".ui-menu-item" ) }; this.collapseAll( event, true ); this._trigger( "select", event, ui );