You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by sv...@apache.org on 2014/11/13 14:41:37 UTC

wicket git commit: WICKET-5755 requestFocus must still be called via setTimeout in IE<9

Repository: wicket
Updated Branches:
  refs/heads/wicket-6.x e850af675 -> 5e1ef91dc


WICKET-5755 requestFocus must still be called via setTimeout in IE<9


Project: http://git-wip-us.apache.org/repos/asf/wicket/repo
Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/5e1ef91d
Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/5e1ef91d
Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/5e1ef91d

Branch: refs/heads/wicket-6.x
Commit: 5e1ef91dcdc1026e13056ee21d6ba98638f37dd8
Parents: e850af6
Author: svenmeier <sv...@meiers.net>
Authored: Thu Nov 13 14:41:02 2014 +0100
Committer: svenmeier <sv...@meiers.net>
Committed: Thu Nov 13 14:41:02 2014 +0100

----------------------------------------------------------------------
 .../java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js  | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/wicket/blob/5e1ef91d/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js
----------------------------------------------------------------------
diff --git a/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js b/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js
index 694ef0e..9a3ce36 100644
--- a/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js
+++ b/wicket-core/src/main/java/org/apache/wicket/ajax/res/js/wicket-ajax-jquery.js
@@ -1052,7 +1052,12 @@
 				Wicket.Focus.attachFocusEvent();
 
 				// set the focus to the last component
-				Wicket.Focus.requestFocus();
+				if (Wicket.Browser.isIELessThan9()) {
+					// WICKET-5755
+					window.setTimeout("Wicket.Focus.requestFocus();", 0);
+				} else {
+					Wicket.Focus.requestFocus();
+				}
 
 				// continue to next step (which should make the processing stop, as success should be the final step)
 				return FunctionsExecuter.DONE;