Author: nbelaevski
Date: 2008-04-30 15:39:20 -0400 (Wed, 30 Apr 2008)
New Revision: 8391
Modified:
trunk/ui/panelmenu/src/main/java/org/richfaces/component/UIPanelMenuGroup.java
Log:
http://jira.jboss.com/jira/browse/RF-2940
Modified: trunk/ui/panelmenu/src/main/java/org/richfaces/component/UIPanelMenuGroup.java
===================================================================
---
trunk/ui/panelmenu/src/main/java/org/richfaces/component/UIPanelMenuGroup.java 2008-04-30
17:43:50 UTC (rev 8390)
+++
trunk/ui/panelmenu/src/main/java/org/richfaces/component/UIPanelMenuGroup.java 2008-04-30
19:39:20 UTC (rev 8391)
@@ -29,6 +29,7 @@
import javax.faces.event.ActionEvent;
import javax.faces.event.ActionListener;
import javax.faces.event.FacesEvent;
+import javax.faces.event.FacesListener;
import javax.faces.event.PhaseId;
import org.ajax4jsf.component.AjaxInputComponent;
@@ -124,9 +125,16 @@
}
public void broadcast(FacesEvent event) throws AbortProcessingException {
- super.broadcast(event);
if(event instanceof ActionEvent){
- FacesContext context = getFacesContext();
+ //workaround for
https://issues.apache.org/jira/browse/MYFACES-1871
+ FacesListener[] listeners = getFacesListeners(FacesListener.class);
+ for (FacesListener listener : listeners) {
+ if (event.isAppropriateListener(listener)) {
+ event.processListener(listener);
+ }
+ }
+
+ FacesContext context = getFacesContext();
// Notify the specified action listener method (if any)
MethodBinding mb = getActionListener();
if (mb != null) {
@@ -139,6 +147,8 @@
if (listener != null) {
listener.processAction((ActionEvent) event);
}
+ } else {
+ super.broadcast(event);
}
}