flex transiton

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute">
 <mx:transitions>
  <mx:Transition id="myTransition" fromState="*" toState="Advanced">
   <mx:Parallel target="{myVBox}">
    <mx:WipeDown duration="2000"/>
    <mx:Dissolve alphaFrom="0.0"  alphaTo="1.0" duration="2000"/>
   </mx:Parallel>
  </mx:Transition>
  
 </mx:transitions>
  
 <mx:states>
  
   <mx:State name="Advanced">
   <mx:AddChild relativeTo="{panel1}" position="lastChild">
    <mx:VBox x="20" y="160" width="160" height="80" id="myVBox">
     <mx:CheckBox  label="check1"/>
     <mx:CheckBox  label="check2"/>
     <mx:CheckBox label="check3"/>
    </mx:VBox>
   </mx:AddChild>
   
  </mx:State>
 </mx:states>
 <mx:Panel id="panel1" width="300" height="400" x="5" y="5">
  <mx:Label x="20" y="70" text="Search"/>
  <mx:TextInput x="20" y="90"/>
  <mx:Button x="185" y="90" label="GO" click="currentState=&quot;&quot;" id="button1"/>
  <mx:LinkButton x="20" y="120" label="Advanced Options" click="currentState=&quot;Advanced&quot;"/>
 </mx:Panel>

 
</mx:Application>

你可能感兴趣的:(Flex)