tabBarIcon.mxml <?xml version=”1.0″ encoding=”utf-8″?>
<mx:Application xmlns:mx=” http://www.adobe.com/2006/mxml ” layout=”vertical” verticalAlign=”middle” backgroundColor=”white”>
<mx:Script>
<![CDATA[
[Bindable]
[Embed(source=”smiley.gif”)]
private var BulletCheck:Class;
[Bindable]
[Embed(source=”smiley.gif”)]
private var BulletWarning:Class;
[Bindable]
[Embed(source=”smiley.gif”)]
private var BulletCritical:Class;
]]>
</mx:Script>
<mx:VBox id=”box” width=”400″ verticalGap=”0″>
<mx:TabBar id=”tabBar” direction=”horizontal” dataProvider=”{viewStack}” width=”100%” />
<mx:ViewStack id=”viewStack” width=”100%” height=”100″ backgroundColor=”white” borderSides=”left bottom right” borderStyle=”solid” borderThickness=”1″>
<mx:Canvas id=”child1″ label=”Success” icon=”{BulletCheck}”>
<mx:Label text=”one” />
</mx:Canvas>
<mx:Canvas id=”child2″ label=”Warning” icon=”{BulletWarning}”>
<mx:Label text=”two” />
</mx:Canvas>
<mx:Canvas id=”child3″ label=”Error” icon=”{BulletCritical}”>
<mx:Label text=”three” />
</mx:Canvas>
</mx:ViewStack>
</mx:VBox>
</mx:Application> |
0 comments:
Post a Comment