Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
Adobe Flex SDK Previous
-
None
-
Affected OS(s): All OS Platforms
Language Found: English
Description
Steps to reproduce:
1. Create a ListCollectionView with Objects that have object-typed properties.
For example:
<s:ArrayCollection id="dp1">
<fx:Object id="obj1">
<fx:address>
<fx:Object town='waltham' state='MA' zipCode='02452'/>
</fx:address>
</fx:Object>
<fx:Object id="obj2">
<fx:address>
<fx:Object town='wilmington' state='MA' zipCode='01887'/>
</fx:address>
</fx:Object>
</s:ArrayCollection>
2. Sort the ListCollectionView using the object-typed property (ex. "address"), but without a compareFunction.
3. Try to use getItemIndex() on the LCV.
See attached file for example. Steps are:
1. click "sort collection".
2. click "getItemIndex from sorted ArrayCollection".
Actual Results:
Throws SortError
Expected Results:
No Error
Workaround (if any):
Use a compareFunction, or remove the sort before using getItemIndex().