myfaces-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From lu4...@apache.org
Subject svn commit: r905504 - in /myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag: jstl/core/ChooseHandler.java jstl/core/ForEachHandler.java jstl/core/IfHandler.java ui/IncludeHandler.java
Date Tue, 02 Feb 2010 03:38:40 GMT
Author: lu4242
Date: Tue Feb  2 03:38:33 2010
New Revision: 905504

URL: http://svn.apache.org/viewvc?rev=905504&view=rev
Log:
MYFACES-2483 Find a way to allow c:if work with partial state saving enabled

Modified:
    myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/jstl/core/ChooseHandler.java
    myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/jstl/core/ForEachHandler.java
    myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/jstl/core/IfHandler.java
    myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/ui/IncludeHandler.java

Modified: myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/jstl/core/ChooseHandler.java
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/jstl/core/ChooseHandler.java?rev=905504&r1=905503&r2=905504&view=diff
==============================================================================
--- myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/jstl/core/ChooseHandler.java
(original)
+++ myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/jstl/core/ChooseHandler.java
Tue Feb  2 03:38:33 2010
@@ -33,6 +33,7 @@
 import javax.faces.view.facelets.TagHandler;
 
 import org.apache.myfaces.buildtools.maven2.plugin.builder.annotation.JSFFaceletTag;
+import org.apache.myfaces.shared_impl.config.MyfacesConfig;
 import org.apache.myfaces.view.facelets.AbstractFaceletContext;
 import org.apache.myfaces.view.facelets.tag.TagHandlerUtils;
 import org.apache.myfaces.view.facelets.tag.jsf.ComponentSupport;
@@ -96,7 +97,10 @@
             this.otherwise.apply(ctx, parent);
         }
         AbstractFaceletContext actx = (AbstractFaceletContext) ctx;
-        if (actx.isMarkInitialState() && actx.isRefreshTransientBuildOnPSS())
+        if (actx.isMarkInitialState() && actx.isRefreshTransientBuildOnPSS() &&
+                MyfacesConfig.getCurrentInstance(
+                        ctx.getFacesContext().getExternalContext()).
+                        isRefreshTransientBuildOnPSSPreserveState())
         {
             //Mark the parent component to be saved and restored fully.
             ComponentSupport.markComponentToRestoreFully(ctx.getFacesContext(), parent);

Modified: myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/jstl/core/ForEachHandler.java
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/jstl/core/ForEachHandler.java?rev=905504&r1=905503&r2=905504&view=diff
==============================================================================
--- myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/jstl/core/ForEachHandler.java
(original)
+++ myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/jstl/core/ForEachHandler.java
Tue Feb  2 03:38:33 2010
@@ -39,6 +39,7 @@
 
 import org.apache.myfaces.buildtools.maven2.plugin.builder.annotation.JSFFaceletAttribute;
 import org.apache.myfaces.buildtools.maven2.plugin.builder.annotation.JSFFaceletTag;
+import org.apache.myfaces.shared_impl.config.MyfacesConfig;
 import org.apache.myfaces.view.facelets.AbstractFaceletContext;
 import org.apache.myfaces.view.facelets.tag.jsf.ComponentSupport;
 
@@ -278,7 +279,10 @@
             }
         }
         AbstractFaceletContext actx = (AbstractFaceletContext) ctx;
-        if (actx.isMarkInitialState() && actx.isRefreshTransientBuildOnPSS())
+        if (actx.isMarkInitialState() && actx.isRefreshTransientBuildOnPSS() &&
+                MyfacesConfig.getCurrentInstance(
+                        ctx.getFacesContext().getExternalContext()).
+                        isRefreshTransientBuildOnPSSPreserveState())
         {
             //Mark the parent component to be saved and restored fully.
             ComponentSupport.markComponentToRestoreFully(ctx.getFacesContext(), parent);

Modified: myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/jstl/core/IfHandler.java
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/jstl/core/IfHandler.java?rev=905504&r1=905503&r2=905504&view=diff
==============================================================================
--- myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/jstl/core/IfHandler.java
(original)
+++ myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/jstl/core/IfHandler.java
Tue Feb  2 03:38:33 2010
@@ -30,6 +30,7 @@
 
 import org.apache.myfaces.buildtools.maven2.plugin.builder.annotation.JSFFaceletAttribute;
 import org.apache.myfaces.buildtools.maven2.plugin.builder.annotation.JSFFaceletTag;
+import org.apache.myfaces.shared_impl.config.MyfacesConfig;
 import org.apache.myfaces.view.facelets.AbstractFaceletContext;
 import org.apache.myfaces.view.facelets.tag.jsf.ComponentSupport;
 
@@ -86,7 +87,10 @@
             this.nextHandler.apply(ctx, parent);
         }
         AbstractFaceletContext actx = (AbstractFaceletContext) ctx;
-        if (actx.isMarkInitialState() && actx.isRefreshTransientBuildOnPSS())
+        if (actx.isMarkInitialState() && actx.isRefreshTransientBuildOnPSS() &&
+                MyfacesConfig.getCurrentInstance(
+                        ctx.getFacesContext().getExternalContext()).
+                        isRefreshTransientBuildOnPSSPreserveState())
         {
             //Mark the parent component to be saved and restored fully.
             ComponentSupport.markComponentToRestoreFully(ctx.getFacesContext(), parent);

Modified: myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/ui/IncludeHandler.java
URL: http://svn.apache.org/viewvc/myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/ui/IncludeHandler.java?rev=905504&r1=905503&r2=905504&view=diff
==============================================================================
--- myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/ui/IncludeHandler.java
(original)
+++ myfaces/core/trunk/impl/src/main/java/org/apache/myfaces/view/facelets/tag/ui/IncludeHandler.java
Tue Feb  2 03:38:33 2010
@@ -37,6 +37,7 @@
 
 import org.apache.myfaces.buildtools.maven2.plugin.builder.annotation.JSFFaceletAttribute;
 import org.apache.myfaces.buildtools.maven2.plugin.builder.annotation.JSFFaceletTag;
+import org.apache.myfaces.shared_impl.config.MyfacesConfig;
 import org.apache.myfaces.view.facelets.AbstractFaceletContext;
 import org.apache.myfaces.view.facelets.el.VariableMapperWrapper;
 import org.apache.myfaces.view.facelets.tag.jsf.ComponentSupport;
@@ -136,7 +137,11 @@
             ctx.setVariableMapper(orig);
         }
         AbstractFaceletContext actx = (AbstractFaceletContext) ctx;
-        if ( !src.isLiteral() && actx.isMarkInitialState() && actx.isRefreshTransientBuildOnPSS())
+        if ( !src.isLiteral() && actx.isMarkInitialState() && 
+              actx.isRefreshTransientBuildOnPSS() && 
+              MyfacesConfig.getCurrentInstance(
+                      ctx.getFacesContext().getExternalContext()).
+                      isRefreshTransientBuildOnPSSPreserveState())
         {
             //Mark the parent component to be saved and restored fully.
             ComponentSupport.markComponentToRestoreFully(ctx.getFacesContext(), parent);



Mime
View raw message