diff options
author | TJ VanToll <tj.vantoll@gmail.com> | 2014-10-25 09:18:17 -0700 |
---|---|---|
committer | TJ VanToll <tj.vantoll@gmail.com> | 2014-10-25 10:10:30 -0700 |
commit | de2ef2a585447cf75fc8d4a734c12aa2bbd028c2 (patch) | |
tree | 38f5491fedb4668ff8a55ea38934bf7f5561d777 /tests/unit/menu/menu_core.js | |
parent | 3002d460de2b854243d99634e69d394dfca78886 (diff) | |
download | jquery-ui-de2ef2a585447cf75fc8d4a734c12aa2bbd028c2.tar.gz jquery-ui-de2ef2a585447cf75fc8d4a734c12aa2bbd028c2.zip |
Menu: Wrap menu items in a <div>
This avoids styling issues where ui-state-focus rules apply to submenus.
Fixes #10162
Closes gh-1342
Diffstat (limited to 'tests/unit/menu/menu_core.js')
-rw-r--r-- | tests/unit/menu/menu_core.js | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/unit/menu/menu_core.js b/tests/unit/menu/menu_core.js index df039c9e4..f02f97fca 100644 --- a/tests/unit/menu/menu_core.js +++ b/tests/unit/menu/menu_core.js @@ -48,12 +48,13 @@ asyncTest( "#9044: Autofocus issue with dialog opened from menu widget", functio asyncTest( "#9532: Need a way in Menu to keep ui-state-active class on selected item for Selectmenu", function() { expect( 1 ); var element = $( "#menu1" ).menu(), - firstChild = element.children().eq( 0 ); + firstChild = element.children().eq( 0 ), + wrapper = firstChild.children( ".ui-menu-item-wrapper" ); element.menu( "focus", null, firstChild ); - firstChild.addClass( "ui-state-active" ); + wrapper.addClass( "ui-state-active" ); setTimeout( function() { - ok( firstChild.is( ".ui-state-active" ), "ui-state-active improperly removed" ); + ok( wrapper.is( ".ui-state-active" ), "ui-state-active improperly removed" ); start(); }, 500 ); }); |