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 2015/08/05 12:07:53 UTC
[2/2] wicket git commit: WICKET-5960 drop headerResponse and
renderedComponentsPerScope in #onAfterRender(),
so a second rendering re-renders the header
WICKET-5960 drop headerResponse and renderedComponentsPerScope in #onAfterRender(), so a second rendering re-renders the header
Project: http://git-wip-us.apache.org/repos/asf/wicket/repo
Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/c34f2f9d
Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/c34f2f9d
Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/c34f2f9d
Branch: refs/heads/wicket-6.x
Commit: c34f2f9dd2838d075968280b042b8826e325f012
Parents: 4601ff3
Author: Sven Meier <sv...@apache.org>
Authored: Tue Aug 4 21:28:34 2015 +0200
Committer: Sven Meier <sv...@apache.org>
Committed: Wed Aug 5 12:04:36 2015 +0200
----------------------------------------------------------------------
.../html/internal/HtmlHeaderContainer.java | 5 ++---
.../wicket/request/cycle/RerenderPage.java | 16 ++++++++++++++++
.../wicket/request/cycle/RerenderPageTest.java | 20 +++++++++++++++++---
3 files changed, 35 insertions(+), 6 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/wicket/blob/c34f2f9d/wicket-core/src/main/java/org/apache/wicket/markup/html/internal/HtmlHeaderContainer.java
----------------------------------------------------------------------
diff --git a/wicket-core/src/main/java/org/apache/wicket/markup/html/internal/HtmlHeaderContainer.java b/wicket-core/src/main/java/org/apache/wicket/markup/html/internal/HtmlHeaderContainer.java
index 17e9c5e..c32131c 100644
--- a/wicket-core/src/main/java/org/apache/wicket/markup/html/internal/HtmlHeaderContainer.java
+++ b/wicket-core/src/main/java/org/apache/wicket/markup/html/internal/HtmlHeaderContainer.java
@@ -313,9 +313,8 @@ public class HtmlHeaderContainer extends TransparentWebMarkupContainer
}
@Override
- protected void onDetach()
- {
- super.onDetach();
+ protected void onAfterRender() {
+ super.onAfterRender();
renderedComponentsPerScope = null;
headerResponse = null;
http://git-wip-us.apache.org/repos/asf/wicket/blob/c34f2f9d/wicket-core/src/test/java/org/apache/wicket/request/cycle/RerenderPage.java
----------------------------------------------------------------------
diff --git a/wicket-core/src/test/java/org/apache/wicket/request/cycle/RerenderPage.java b/wicket-core/src/test/java/org/apache/wicket/request/cycle/RerenderPage.java
index 82aed54..fc0ed3e 100644
--- a/wicket-core/src/test/java/org/apache/wicket/request/cycle/RerenderPage.java
+++ b/wicket-core/src/test/java/org/apache/wicket/request/cycle/RerenderPage.java
@@ -1,3 +1,19 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package org.apache.wicket.request.cycle;
import java.io.Serializable;
http://git-wip-us.apache.org/repos/asf/wicket/blob/c34f2f9d/wicket-core/src/test/java/org/apache/wicket/request/cycle/RerenderPageTest.java
----------------------------------------------------------------------
diff --git a/wicket-core/src/test/java/org/apache/wicket/request/cycle/RerenderPageTest.java b/wicket-core/src/test/java/org/apache/wicket/request/cycle/RerenderPageTest.java
index 1c4fefb..35a607c 100644
--- a/wicket-core/src/test/java/org/apache/wicket/request/cycle/RerenderPageTest.java
+++ b/wicket-core/src/test/java/org/apache/wicket/request/cycle/RerenderPageTest.java
@@ -1,10 +1,25 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
package org.apache.wicket.request.cycle;
+import org.apache.wicket.WicketTestCase;
import org.apache.wicket.core.request.mapper.MountedMapper;
import org.apache.wicket.request.cycle.RerenderPage.Supplier;
import org.apache.wicket.request.mapper.parameter.PageParameters;
-import org.apache.wicket.util.tester.WicketTestCase;
-import org.junit.Ignore;
import org.junit.Test;
/**
@@ -20,7 +35,6 @@ public class RerenderPageTest extends WicketTestCase
* because it was already rendered in the first try.
*/
@Test
- @Ignore("Committed reproduction case, but added disabled to not fail the build")
public void wicket5960()
{
// mount the page so we have URL segments