myfaces-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hno...@apache.org
Subject [myfaces-tobago] branch master updated: TOBAGO-1909 Component with style tag inside a grid layout lead to a ServletException
Date Wed, 25 Jul 2018 13:59:28 GMT
This is an automated email from the ASF dual-hosted git repository.

hnoeth pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/myfaces-tobago.git


The following commit(s) were added to refs/heads/master by this push:
     new f987dd1  TOBAGO-1909 Component with style tag inside a grid layout lead to a ServletException
f987dd1 is described below

commit f987dd104022344ff4c6704bc9d11a639e7cde8f
Author: Henning Noeth <hnoeth@apache.org>
AuthorDate: Wed Jul 25 15:59:20 2018 +0200

    TOBAGO-1909 Component with style tag inside a grid layout lead to a ServletException
    
    * style tag inside grid layout is now always transient
---
 .../myfaces/tobago/internal/component/AbstractUIGridLayout.java       | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIGridLayout.java
b/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIGridLayout.java
index 6f594cc..4ab39c9 100644
--- a/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIGridLayout.java
+++ b/tobago-core/src/main/java/org/apache/myfaces/tobago/internal/component/AbstractUIGridLayout.java
@@ -166,9 +166,11 @@ public abstract class AbstractUIGridLayout extends AbstractUILayoutBase
       if (style == null) {
         style = (UIStyle) ComponentUtils.createComponent(
             facesContext, UIStyle.COMPONENT_TYPE, RendererTypes.Style, null);
-        style.setTransient(true);
         component.getChildren().add(style);
       }
+      // Style must be transient to avoid creating a new instance of GridSpan while restore
state
+      // https://issues.apache.org/jira/browse/TOBAGO-1909
+      style.setTransient(true);
 
       final Integer gridColumn = (Integer) attributes.get(Attributes.gridColumn.getName());
       final Integer columnSpan = (Integer) attributes.get(Attributes.columnSpan.getName());


Mime
View raw message