r3380 committed - autocomplete: combox, hide suggestions when clicking the button again
Revision: 3380
Author: joern.zaefferer
Date: Thu Oct 22 11:54:28 2009
Log: autocomplete: combox, hide suggestions when clicking the button again
http://code.google.com/p/jquery-ui/source/detail?r=3380
Modified:
/branches/dev/tests/visual/autocomplete/combobox.html
=======================================
--- /branches/dev/tests/visual/autocomplete/combobox.html Thu Oct 22
11:49:35 2009
+++ /branches/dev/tests/visual/autocomplete/combobox.html Thu Oct 22
11:54:28 2009
@@ -59,6 +59,11 @@
offset: "-1 0"
})
.click(function() {
+ // close if already visible
+ if (input.autocomplete("widget").is(":visible")) {
+ input.autocomplete("close");
+ return;
+ }
// need to temporarily remove value for search to display all options
// find a better solution to avoid the flashing
var val = input.val();