You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by lu...@apache.org on 2008/08/02 18:15:05 UTC

svn commit: r682003 - /myfaces/core/trunk_1.2.x/api/src/main/java/javax/faces/component/UIViewRoot.java

Author: lu4242
Date: Sat Aug  2 09:15:04 2008
New Revision: 682003

URL: http://svn.apache.org/viewvc?rev=682003&view=rev
Log:
MYFACES-1895 state saving and events (_events is a transient variable and should not be included on save and restore state methods)

Modified:
    myfaces/core/trunk_1.2.x/api/src/main/java/javax/faces/component/UIViewRoot.java

Modified: myfaces/core/trunk_1.2.x/api/src/main/java/javax/faces/component/UIViewRoot.java
URL: http://svn.apache.org/viewvc/myfaces/core/trunk_1.2.x/api/src/main/java/javax/faces/component/UIViewRoot.java?rev=682003&r1=682002&r2=682003&view=diff
==============================================================================
--- myfaces/core/trunk_1.2.x/api/src/main/java/javax/faces/component/UIViewRoot.java (original)
+++ myfaces/core/trunk_1.2.x/api/src/main/java/javax/faces/component/UIViewRoot.java Sat Aug  2 09:15:04 2008
@@ -614,16 +614,15 @@
   @Override
   public Object saveState(FacesContext facesContext)
   {
-    Object[] values = new Object[10];
+    Object[] values = new Object[8];
     values[0] = super.saveState(facesContext);
     values[1] = _locale;
     values[2] = _renderKitId;
     values[3] = _viewId;
-    values[4] = saveAttachedState(facesContext, _events);
-    values[5] = _uniqueIdCounter;
-    values[7] = saveAttachedState(facesContext, _phaseListeners);
-    values[8] = saveAttachedState(facesContext, _beforePhaseListener);
-    values[9] = saveAttachedState(facesContext, _afterPhaseListener);
+    values[4] = _uniqueIdCounter;
+    values[5] = saveAttachedState(facesContext, _phaseListeners);
+    values[6] = saveAttachedState(facesContext, _beforePhaseListener);
+    values[7] = saveAttachedState(facesContext, _afterPhaseListener);
 
     return values;
   }
@@ -636,11 +635,10 @@
     _locale = (Locale)values[1];
     _renderKitId = (String)values[2];
     _viewId = (String)values[3];
-    _events = (List)restoreAttachedState(facesContext, values[4]);
-    _uniqueIdCounter = (Long)values[5];
-    _phaseListeners = (List) restoreAttachedState(facesContext, values[7]);
-    _beforePhaseListener = (MethodExpression)restoreAttachedState(facesContext, values[8]);
-    _afterPhaseListener = (MethodExpression)restoreAttachedState(facesContext, values[9]);
+    _uniqueIdCounter = (Long)values[4];
+    _phaseListeners = (List) restoreAttachedState(facesContext, values[5]);
+    _beforePhaseListener = (MethodExpression)restoreAttachedState(facesContext, values[6]);
+    _afterPhaseListener = (MethodExpression)restoreAttachedState(facesContext, values[7]);
   }
 
   @Override