Uploaded image for project: 'Apache Flex'
  1. Apache Flex
  2. FLEX-27307

FlexEvent.ADD and FlexEvent.REMOVE not dispatching in Flex 4 SDK

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • Adobe Flex SDK 4.0 (Release)
    • None
    • Events
    • None
    • Affected OS(s): All OS Platforms
      Affected OS(s): All OS Platforms
      Browser: Internet Explorer 8.x
      Language Found: English

    Description

      Steps to reproduce:
      1. add and eventlistener for the add and remove events on a component
      2. add the component to the container

      Actual Results:

      Listener is not called

      Expected Results:

      Listener gets called

      Workaround (if any):

      The problem appears to be in Container.as. The following line was added in 4.0:

      if (hasEventListener(FlexEvent.ADD)) /** new line **/
      child.dispatchEvent(new FlexEvent(FlexEvent.ADD));

      before calling dispatch. Thus, the parent must have the "ADD" listener for it to work. This is incorrect. The child should be checked for the listener not "this".

      Attachments

        Activity

          People

            Unassigned Unassigned
            adobejira Adobe JIRA
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: