Browse files

Selectmenu: improved ARIA handling (follow-up)

  • Loading branch information...
1 parent 1538f63 commit 6d0c7d8e88361bc5605950aa925316d37a42d89b @fnagel fnagel committed Dec 22, 2011
Showing with 1 addition and 1 deletion.
  1. +1 −1 ui/jquery.ui.selectmenu.js
View
2 ui/jquery.ui.selectmenu.js
@@ -171,10 +171,10 @@ $.widget( "ui.selectmenu", {
this._renderMenu( this.menu, this.items );
this.menu.menu( "refresh" );
- this.menu.menu( "focus", null, this._getSelectedItem() );
// adjust ARIA
this.menu.find( "li" ).not( '.ui-selectmenu-optgroup' ).find( 'a' ).attr( 'role', 'option' );
+ this.menu.attr( "aria-activedescendant" , this.menu.find( "li.ui-menu-item a" ).eq( this.element[0].selectedIndex ).attr( "id" ) );
if ( this.options.dropdown ) {
this.menu

0 comments on commit 6d0c7d8

Please sign in to comment.