Is it possible to play an effect when the data provider feeding a UIComponent 
is filtered using a filter function? For example in the following code, 
when the non-citrus checkboxes are removed, I'd like them to play the fadeOut 
effect but instead they are just removed immediately.

<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"; layout="vertical" 
creationComplete="creationComplete()">
        <mx:Script>
                <![CDATA[
                        import mx.collections.ArrayCollection;
                        
                        [Bindable]
                        private var fruits:ArrayCollection = new 
ArrayCollection (["Apple","Orange","Lemon","Grape"]);
                        
                        private function isCitrus(item:String):Boolean
                        {
                                return (item == "Orange" || item == "Lemon");
                        }
                
                        private function creationComplete():void
                        {
                                fruits.filterFunction = isCitrus;
                        }
                ]]>
        </mx:Script>
        <mx:Button click="fruits.refresh()" label="Show Citrus"/>
        <mx:Repeater id="fruitCBs" dataProvider="{fruits}">
                <mx:CheckBox label="{fruitCBs.currentItem}" 
hideEffect="{fadeOut}"/>
        </mx:Repeater>
        <mx:Fade id="fadeOut" duration="1000" alphaFrom="1.0" alphaTo="0.0"/>
</mx:Application>

Reply via email to