You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Leonardo Uribe (JIRA)" <de...@myfaces.apache.org> on 2010/05/05 04:36:03 UTC

[jira] Created: (MYFACES-2699) UIComponent.broadcast should propagate events to all Behavior instances, not only to ClientBehavior

UIComponent.broadcast should propagate events to all Behavior instances, not only to ClientBehavior
---------------------------------------------------------------------------------------------------

                 Key: MYFACES-2699
                 URL: https://issues.apache.org/jira/browse/MYFACES-2699
             Project: MyFaces Core
          Issue Type: Bug
          Components: JSR-314
    Affects Versions: 2.0.0
            Reporter: Leonardo Uribe
            Assignee: Leonardo Uribe


Checking the new Behavior api (for implement cc:clientBehavior), I note that the javadoc of UIComponent.broadcast says this:

"....Broadcast the specified FacesEvent to all registered event listeners who have expressed an interest in events of this type. Listeners are called in the order in which they were added.

If the event is an instance of BehaviorEvent and the current component is the source of the event call BehaviorEvent.getBehavior() to get the Behavior for the event. If the behavior implements ClientBehavior, call Behavior.broadcast(javax.faces.event.BehaviorEvent)}....."

The wrong line is:

".....If the behavior implements ClientBehavior, call Behavior.broadcast....."

So, if a user try to create a custom Behavior, the method broadcast() will be useless, and custom behaviors will not catch events. I think it is a bug on the javadoc, so I'll correct it on myfaces.


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (MYFACES-2699) UIComponent.broadcast should propagate events to all Behavior instances, not only to ClientBehavior

Posted by "Leonardo Uribe (JIRA)" <de...@myfaces.apache.org>.
     [ https://issues.apache.org/jira/browse/MYFACES-2699?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Leonardo Uribe resolved MYFACES-2699.
-------------------------------------

    Fix Version/s: 2.0.1-SNAPSHOT
       Resolution: Fixed

> UIComponent.broadcast should propagate events to all Behavior instances, not only to ClientBehavior
> ---------------------------------------------------------------------------------------------------
>
>                 Key: MYFACES-2699
>                 URL: https://issues.apache.org/jira/browse/MYFACES-2699
>             Project: MyFaces Core
>          Issue Type: Bug
>          Components: JSR-314
>    Affects Versions: 2.0.0
>            Reporter: Leonardo Uribe
>            Assignee: Leonardo Uribe
>             Fix For: 2.0.1-SNAPSHOT
>
>
> Checking the new Behavior api (for implement cc:clientBehavior), I note that the javadoc of UIComponent.broadcast says this:
> "....Broadcast the specified FacesEvent to all registered event listeners who have expressed an interest in events of this type. Listeners are called in the order in which they were added.
> If the event is an instance of BehaviorEvent and the current component is the source of the event call BehaviorEvent.getBehavior() to get the Behavior for the event. If the behavior implements ClientBehavior, call Behavior.broadcast(javax.faces.event.BehaviorEvent)}....."
> The wrong line is:
> ".....If the behavior implements ClientBehavior, call Behavior.broadcast....."
> So, if a user try to create a custom Behavior, the method broadcast() will be useless, and custom behaviors will not catch events. I think it is a bug on the javadoc, so I'll correct it on myfaces.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.