aboutsummaryrefslogtreecommitdiffstats
path: root/ui/jquery.ui.autocomplete.js
diff options
context:
space:
mode:
authorScott González <scott.gonzalez@gmail.com>2010-07-20 15:13:54 -0400
committerScott González <scott.gonzalez@gmail.com>2010-07-20 15:13:54 -0400
commite85615fc6b1d636f4bcea3abd3a6091f937858b8 (patch)
tree29385901beff401a98f84e7f1af377a9c9948160 /ui/jquery.ui.autocomplete.js
parent123467af8efc8541e333979a59ca9db36fec9cda (diff)
downloadjquery-ui-e85615fc6b1d636f4bcea3abd3a6091f937858b8.tar.gz
jquery-ui-e85615fc6b1d636f4bcea3abd3a6091f937858b8.zip
Autocomplete: Prevent the default behavior of pressing enter when the menu is open, even if no item is active. Partial fix for #5757 - Autocomplete combobox issues.
Diffstat (limited to 'ui/jquery.ui.autocomplete.js')
-rw-r--r--ui/jquery.ui.autocomplete.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/ui/jquery.ui.autocomplete.js b/ui/jquery.ui.autocomplete.js
index b9daad86b..4b37a000d 100644
--- a/ui/jquery.ui.autocomplete.js
+++ b/ui/jquery.ui.autocomplete.js
@@ -59,7 +59,7 @@ $.widget( "ui.autocomplete", {
case keyCode.ENTER:
case keyCode.NUMPAD_ENTER:
// when menu is open or has focus
- if ( self.menu.active ) {
+ if ( self.menu.element.is( ":visible" ) ) {
event.preventDefault();
}
//passthrough - ENTER and TAB both select the current element