Repository: wicket
Updated Branches:
  refs/heads/wicket-7.x b0bec66f7 -> 24500049d


WICKET-6351 Form.anyFormComponentError performance degradation


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

Branch: refs/heads/wicket-7.x
Commit: 24500049ddeedfb6d536f07326f002e923c72a33
Parents: b0bec66
Author: Martin Tzvetanov Grigorov <[email protected]>
Authored: Mon Apr 3 11:19:02 2017 +0200
Committer: Martin Tzvetanov Grigorov <[email protected]>
Committed: Mon Apr 3 11:20:04 2017 +0200

----------------------------------------------------------------------
 .../src/main/java/org/apache/wicket/markup/html/form/Form.java | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/wicket/blob/24500049/wicket-core/src/main/java/org/apache/wicket/markup/html/form/Form.java
----------------------------------------------------------------------
diff --git 
a/wicket-core/src/main/java/org/apache/wicket/markup/html/form/Form.java 
b/wicket-core/src/main/java/org/apache/wicket/markup/html/form/Form.java
index a67304d..23eb581 100644
--- a/wicket-core/src/main/java/org/apache/wicket/markup/html/form/Form.java
+++ b/wicket-core/src/main/java/org/apache/wicket/markup/html/form/Form.java
@@ -1025,8 +1025,7 @@ public class Form<T> extends WebMarkupContainer
                        public void component(final Component component, final 
IVisit<Void> visit)
                        {
                                Form<?> form = (Form<?>)component;
-                               if (form.isEnabledInHierarchy() && 
form.isVisibleInHierarchy() &&
-                                       form.wantSubmitOnParentFormSubmit())
+                               if (form.wantSubmitOnParentFormSubmit() && 
form.isEnabledInHierarchy() && form.isVisibleInHierarchy())
                                {
                                        form.setFlag(FLAG_SUBMITTED, true);
                                        return;
@@ -1168,8 +1167,7 @@ public class Form<T> extends WebMarkupContainer
                        @Override
                        public void component(final Component component, final 
IVisit<Boolean> visit)
                        {
-                               if (component.isVisibleInHierarchy() && 
component.isEnabledInHierarchy() &&
-                                       component.hasErrorMessage())
+                               if (component.hasErrorMessage() && 
component.isVisibleInHierarchy() && component.isEnabledInHierarchy())
                                {
                                        visit.stop(true);
                                }

Reply via email to