blob: 02897c6ce208798e35bdafd8313cd1e886cccda7 [file] [log] [blame]
<?xml version="1.0" encoding="utf-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one or more
contributor license agreements. See the NOTICE file distributed with
this work for additional information regarding copyright ownership.
The ASF licenses this file to You under the Apache License, Version 2.0
(the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<s:View xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark" title="Slide View" backgroundColor="black">
<fx:Script>
<![CDATA[
import mx.events.EffectEvent;
protected function fadeOut_effectEndHandler(event:EffectEvent):void
{
formGrp.visible=true;
}
protected function submitButton_clickHandler(event:MouseEvent):void
{
formGrp.visible=false;
lbl.visible=true;
}
]]>
</fx:Script>
<fx:Declarations>
<s:Fade duration="500" id="fadeOut" alphaFrom=".9" alphaTo="0" effectEnd="fadeOut_effectEndHandler(event)"/>
<s:Sequence id="sq">
<s:Move duration="800" xTo="{this.width/2-170}" xFrom="500"/>
<s:Fade duration="800" id="fadeIn" alphaFrom="0" alphaTo=".9"/>
</s:Sequence>
</fx:Declarations>
<s:HGroup id="formGrp" width="100%" horizontalAlign="center" paddingTop="270" verticalAlign="middle">
<s:Label text="Enter Your Name:" color="0xFFFFFF"/>
<s:TextInput id="txtName" width="160"/>
<s:Button id="submitButton" label="Submit" click="submitButton_clickHandler(event)"/>
</s:HGroup>
<!-- This label shows when the submit button is clicked -->
<s:Label id="lbl" text="{'Thank You '+txtName.text+'!'}" visible="false" showEffect="sq" color="0x993366" fontSize="50" paddingTop="270"/>
</s:View>