This is an automated email from the ASF dual-hosted git repository. mgrigorov pushed a commit to branch wicket-9.x in repository https://gitbox.apache.org/repos/asf/wicket.git
The following commit(s) were added to refs/heads/wicket-9.x by this push: new e7d049b6df Fix tab glitch when tabing from and to an autocomplete field, which resulted in a dropdown that didn't open on first character when returning to the field (#1039) e7d049b6df is described below commit e7d049b6df62e51e979beaa2982253c3d3f07daa Author: Erik Strid <strid.e...@gmail.com> AuthorDate: Tue Nov 19 10:14:17 2024 +0100 Fix tab glitch when tabing from and to an autocomplete field, which resulted in a dropdown that didn't open on first character when returning to the field (#1039) Co-authored-by: Erik Strid <erik.st...@idainfront.se> --- .../extensions/ajax/markup/html/autocomplete/wicket-autocomplete.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/wicket-autocomplete.js b/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/wicket-autocomplete.js index 262c35b1b7..2b2998e60d 100644 --- a/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/wicket-autocomplete.js +++ b/wicket-extensions/src/main/java/org/apache/wicket/extensions/ajax/markup/html/autocomplete/wicket-autocomplete.js @@ -102,7 +102,11 @@ //workaround for IE. Clicks on scrollbar trigger //'blur' event on input field. (See https://issues.apache.org/jira/browse/WICKET-5882) if (menuId !== document.activeElement.id && (menuId + "-container") !== document.activeElement.id) { - hideAutoCompleteTimer = window.setTimeout(hideAutoComplete, 500); + hideAutoCompleteTimer = window.setTimeout(function() { + hideAutoComplete(); + isTriggeredChange = false; + triggerChangeOnHide = false; + }, 500); } else { jQuery(this).trigger("focus"); }