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

HierarchicalCollectionView.contains is not working properly

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Duplicate
    • Adobe Flex SDK Previous
    • Adobe Flex SDK Previous
    • SuperCollections
    • None
    • Affected OS(s): Windows
      Language Found: English

    Description

      HierarchicalCollectionView.contains does:

      public function contains(item:Object):Boolean
      {
      var cursor:IViewCursor = createCursor();
      var done:Boolean = false;
      while (!done)

      { if (cursor.current == item) return true; done = cursor.moveNext(); }

      return false;
      }

      it should be:

      public function contains(item:Object):Boolean
      {
      var cursor:IViewCursor = createCursor();
      var valid:Boolean = true;
      while (valid)

      { if (cursor.current == item) return true; valid = cursor.moveNext(); }

      return false;
      }

      Otherwise it looks only into the first element of the view.

      Attachments

        Activity

          People

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

            Dates

              Created:
              Updated:
              Resolved: