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

In Flex 4.5.1, MOVE events in base list are no longer propagated to listeners of a ListCollectionView wrapper

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • Adobe Flex SDK Previous
    • None
    • Collections
    • None
    • Affected OS(s): All OS Platforms
      Language Found: English

    Description

      Create a ListCollectionView - lcv
      Create a list that generates MOVE events - ml
      Set the list property of lcv to ml
      Add a listener to lcv for COLLECTION_CHANGE event
      Generate a Move Event in ml

      Actual Results:
      Listener for move event is never notified

      Expected Results:
      All MOVE events in base list should propagate, when no filter or sort is defined.

      Workaround (if any):
      The cause of the problem is that moveItemsInView() in LCV is called from listChangeHandler ( wasn't in 4.5). Checks in moveItemsInView for dispatchEvent are never executed if no localIndex exists.

      [Workaround Updated - see below] So workaround is to always subclass LCV to override moveItemsInView so that if localIndex is null, it must test the dispatchEvent flag. Hoever, this is no good for any situations where ListCollectionView is created inside a component e.g. any component deriving from ListBase. In this case, it will be necessary to create the ListCollectionView outside the component bedore setting the dataprovider.

      It's not quite a regression bug since moveItemsInView() was never actually called before so that bit is now fixed.
      In Summary:
      Flex 4.5 - Move events passed transparently to all listeners of ListCollectionView but localIndex never updated
      Flex 4.5.1 - localIndex of ListCollectionView correctly updated with MOVE events but events only passed to listeners if localIndex is defined

      Attachments

        Activity

          People

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

            Dates

              Created:
              Updated: