myfaces-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bom...@apache.org
Subject svn commit: r1066648 - /myfaces/tobago/branches/tobago-1.0.x/core/src/main/java/org/apache/myfaces/tobago/component/UITabGroup.java
Date Wed, 02 Feb 2011 21:58:56 GMT
Author: bommel
Date: Wed Feb  2 21:58:55 2011
New Revision: 1066648

URL: http://svn.apache.org/viewvc?rev=1066648&view=rev
Log:
(TOBAGO-970) Changes in broadcast method should be performed after all listener are called

Modified:
    myfaces/tobago/branches/tobago-1.0.x/core/src/main/java/org/apache/myfaces/tobago/component/UITabGroup.java

Modified: myfaces/tobago/branches/tobago-1.0.x/core/src/main/java/org/apache/myfaces/tobago/component/UITabGroup.java
URL: http://svn.apache.org/viewvc/myfaces/tobago/branches/tobago-1.0.x/core/src/main/java/org/apache/myfaces/tobago/component/UITabGroup.java?rev=1066648&r1=1066647&r2=1066648&view=diff
==============================================================================
--- myfaces/tobago/branches/tobago-1.0.x/core/src/main/java/org/apache/myfaces/tobago/component/UITabGroup.java
(original)
+++ myfaces/tobago/branches/tobago-1.0.x/core/src/main/java/org/apache/myfaces/tobago/component/UITabGroup.java
Wed Feb  2 21:58:55 2011
@@ -236,13 +236,6 @@ public class UITabGroup extends UIPanelB
   public void broadcast(FacesEvent facesEvent) throws AbortProcessingException {
     super.broadcast(facesEvent);
     if (facesEvent instanceof TabChangeEvent && facesEvent.getComponent() == this)
{
-      Integer index = ((TabChangeEvent) facesEvent).getNewTabIndex();
-      ValueBinding vb = getValueBinding(ATTR_SELECTED_INDEX);
-      if (vb != null) {
-        vb.setValue(getFacesContext(), index);
-      } else {
-        setSelectedIndex(index);
-      }
       MethodBinding tabChangeListenerBinding = getTabChangeListener();
       if (tabChangeListenerBinding != null) {
         try {
@@ -256,6 +249,13 @@ public class UITabGroup extends UIPanelB
           }
         }
       }
+      Integer index = ((TabChangeEvent) facesEvent).getNewTabIndex();
+      ValueBinding vb = getValueBinding(ATTR_SELECTED_INDEX);
+      if (vb != null) {
+        vb.setValue(getFacesContext(), index);
+      } else {
+        setSelectedIndex(index);
+      }
       getFacesContext().renderResponse();
     }
   }



Mime
View raw message