mirror of
https://github.com/jquery/jquery-ui.git
synced 2024-10-05 01:44:18 +00:00
Autocomplete: moved autoFocus implementation to after menu visible for a11y
(cherry picked from commit 4026d3acd7
)
This commit is contained in:
parent
1fe58dbf52
commit
3cfba5d9a8
8
ui/jquery.ui.autocomplete.js
vendored
8
ui/jquery.ui.autocomplete.js
vendored
@ -360,16 +360,16 @@ $.widget( "ui.autocomplete", {
|
|||||||
this.menu.deactivate();
|
this.menu.deactivate();
|
||||||
this.menu.refresh();
|
this.menu.refresh();
|
||||||
|
|
||||||
if ( this.options.autoFocus ) {
|
|
||||||
this.menu.next( new $.Event("mouseover") );
|
|
||||||
}
|
|
||||||
|
|
||||||
// size and position menu
|
// size and position menu
|
||||||
ul.show();
|
ul.show();
|
||||||
this._resizeMenu();
|
this._resizeMenu();
|
||||||
ul.position( $.extend({
|
ul.position( $.extend({
|
||||||
of: this.element
|
of: this.element
|
||||||
}, this.options.position ));
|
}, this.options.position ));
|
||||||
|
|
||||||
|
if ( this.options.autoFocus ) {
|
||||||
|
this.menu.next( new $.Event("mouseover") );
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
_resizeMenu: function() {
|
_resizeMenu: function() {
|
||||||
|
Loading…
Reference in New Issue
Block a user