Note that there are some explanatory texts on larger screens.

plurals
  1. POWhy is this Flex 4 Transition not working?
    text
    copied!<p>I have a test application <a href="http://queirozf.com/exampleFlashBuilder/bin-debug/exampleFlashBuilder.html" rel="nofollow">here</a> which was made using the following code:</p> <pre><code>&lt;fx:Script&gt; &lt;![CDATA[ public function comboBoxHandler():void{ var selectedItem:String = showComboBox.selectedItem; if(selectedItem == "All results"){ currentState = "default"; return; }else if(selectedItem == "Only results within tags"){ currentState = "tagInput"; return; } } ]]&gt; &lt;/fx:Script&gt; &lt;s:states&gt; &lt;s:State name="default"/&gt; &lt;s:State name="tagInput"/&gt; &lt;/s:states&gt; &lt;s:transitions&gt; &lt;s:Transition id="showTagTextInput" fromState="default" toState="tagInput"&gt; &lt;s:Sequence id="t1p1" targets="{[tagsLabel,tagsTextInput,GoButton]}"&gt; &lt;s:Move duration="700"/&gt; &lt;s:Fade duration="400"/&gt; &lt;/s:Sequence&gt; &lt;/s:Transition&gt; &lt;s:Transition id="hideTagTextInput" fromState="tagInput" toState="default"&gt; &lt;s:Sequence id="t2p1" targets="{[tagsLabel,tagsTextInput,GoButton]}" &gt; &lt;s:Fade duration="400"/&gt; &lt;s:Move duration="700"/&gt; &lt;/s:Sequence&gt; &lt;/s:Transition&gt; &lt;/s:transitions&gt; &lt;s:Label x="136" y="13" width="120" height="34" fontFamily="Arial" fontSize="15" text="Lessons&amp;#xd;Learnt" textAlign="center"/&gt; &lt;s:Group id="group" width="100%" height="100%" x.default="0" y.default="55" width.default="400" height.default="231" y.tagInput="55" height.tagInput="256"&gt; &lt;s:Label x="45" y="38" width="50" height="22" text="Search" textAlign="center" verticalAlign="middle"/&gt; &lt;s:TextInput x="103" y="38" width="193" useHandCursor.tagInput="false"/&gt; &lt;s:Label x="45" y="89" width="51" height="22" text="Show" textAlign="center" verticalAlign="middle"/&gt; &lt;s:Button id="GoButton" x="253" y="137" width="43" label="Go" useHandCursor="true" buttonMode="true" mouseChildren="false" x.tagInput="254" y.tagInput="188"/&gt; &lt;s:DropDownList id="showComboBox" x="104" y="89" width="192" change="comboBoxHandler();" selectedIndex="0"&gt; &lt;s:ArrayCollection&gt; &lt;fx:String&gt;All results&lt;/fx:String&gt; &lt;fx:String&gt;Only results within tags&lt;/fx:String&gt; &lt;/s:ArrayCollection&gt; &lt;/s:DropDownList&gt; &lt;s:Label id="tagsLabel" includeIn="tagInput" x="104" y="146" width="61" height="20" text="Tags" textAlign="center" verticalAlign="middle"/&gt; &lt;s:TextInput id="tagsTextInput" includeIn="tagInput" x="173" y="146" width="123"/&gt; &lt;/s:Group&gt; </code></pre> <p>You can check, by <strong>clicking the link</strong> I gave, that this app performs some basic transition effect <strong>when you select different options from the DropDownBox</strong>. </p> <p>The first (show) transition doesn't work so well, but the second (hide) transition does.</p> <p>Does anyone know how to fix that? In the first transition, I would like the button to slide down <strong>first</strong>, only after that should the text input fade In. <strong>Why isn't this working?</strong></p> <p>Thanks in advance.</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload