⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 state.mxml

📁 这是一个Flex开发的一个例子,菜单的拉取和拖放
💻 MXML
字号:
<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" horizontalScrollPolicy="off" verticalScrollPolicy="off" backgroundColor="#ffffff">
	<mx:Style>
		Panel {  
   fillColors: #009900, #999933, #3366cc, #660099;
   color: #cc6633;
   textRollOverColor: #cc0066;
   textSelectedColor: #cccc33;
   borderColor: #99cc33;
   fontFamily: Impact;
   fontSize: 24;
   fontWeight: normal;
}
	</mx:Style>
	<mx:transitions>
		<mx:Transition fromState="*" toState="*">
			<mx:Sequence targets="{[p1,p2,p3]}">
				<mx:Move duration="400"/>
				<mx:Rotate angleFrom="0" angleTo="360"/>
				<mx:Resize duration="400" />
			</mx:Sequence>
		</mx:Transition>
	</mx:transitions>
	<mx:states>
		<mx:State name="s1">
			<mx:SetProperty target="{p1}" name="x" value="5"/>
			<mx:SetProperty target="{p1}" name="y" value="60"/>
			<mx:SetProperty target="{p1}" name="height" value="300"/>
			<mx:SetProperty target="{p1}" name="width" value="390"/>
			<mx:SetProperty target="{p2}" name="x" value="135"/>
			<mx:SetProperty target="{p2}" name="y" value="10"/>
			<mx:SetProperty target="{p2}" name="height" value="30"/>
			<mx:SetProperty target="{p2}" name="width" value="125"/>
			<mx:SetProperty target="{p3}" name="x" value="270"/>
			<mx:SetProperty target="{p3}" name="y" value="10"/>
			<mx:SetProperty target="{p3}" name="height" value="30"/>
			<mx:SetProperty target="{p3}" name="width" value="125"/>			
		</mx:State>
			<mx:State name="s2">
			<mx:SetProperty target="{p1}" name="x" value="5"/>
			<mx:SetProperty target="{p1}" name="y" value="10"/>
			<mx:SetProperty target="{p1}" name="height" value="30"/>
			<mx:SetProperty target="{p1}" name="width" value="125"/>
			<mx:SetProperty target="{p2}" name="x" value="5"/>
			<mx:SetProperty target="{p2}" name="y" value="60"/>
			<mx:SetProperty target="{p2}" name="height" value="390"/>
			<mx:SetProperty target="{p2}" name="width" value="300"/>
			<mx:SetProperty target="{p3}" name="x" value="270"/>
			<mx:SetProperty target="{p3}" name="y" value="10"/>
			<mx:SetProperty target="{p3}" name="height" value="30"/>
			<mx:SetProperty target="{p3}" name="width" value="125"/>			
		</mx:State>
			<mx:State name="s3">
			<mx:SetProperty target="{p1}" name="x" value="5"/>
			<mx:SetProperty target="{p1}" name="y" value="10"/>
			<mx:SetProperty target="{p1}" name="height" value="30"/>
			<mx:SetProperty target="{p1}" name="width" value="125"/>
			<mx:SetProperty target="{p2}" name="x" value="135"/>
			<mx:SetProperty target="{p2}" name="y" value="10"/>
			<mx:SetProperty target="{p2}" name="height" value="30"/>
			<mx:SetProperty target="{p2}" name="width" value="125"/>
			<mx:SetProperty target="{p3}" name="x" value="5"/>
			<mx:SetProperty target="{p3}" name="y" value="60"/>
			<mx:SetProperty target="{p3}" name="height" value="390"/>
			<mx:SetProperty target="{p3}" name="width" value="300"/>			
			
		</mx:State>
	</mx:states>
	<mx:Panel id="p1" x="5" y="10" width="125" height="30" layout="absolute" title="Panel1" click="this.currentState='s1'">
	</mx:Panel>
	<mx:Panel id="p2" x="135" y="10" width="125" height="30" layout="absolute" title="Panel2" click="this.currentState='s2'">
	</mx:Panel>
	<mx:Panel  id="p3" x="270" y="10" width="125" height="30" layout="absolute" title="Panel3" click="this.currentState='s3'">
	</mx:Panel>
	<mx:Button x="308" y="596" label="Reset" click="this.currentState=''"/>
	
</mx:Application>

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -