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

📄 navigation.mxml

📁 flex 实现的一个showcase 喜欢flex的朋友可以
💻 MXML
字号:
<?xml version="1.0" encoding="utf-8"?>
<mx:Canvas
	xmlns:mx="http://www.adobe.com/2006/mxml"
	xmlns:panels="com.flexShowcase.panels.*"
	xmlns:components="com.flexShowcase.components.*"
	
	top="10"
	width="760"
	horizontalCenter="0"
	
	horizontalScrollPolicy="off"
	verticalScrollPolicy="off"
	
	clipContent="false"
	creationComplete="creationCompleteHandler(event)">
	
	
	<mx:Script>
		<![CDATA[
			
		
			//////////////////////////////////////////////////
			//import
			
			import com.flexShowcase.constants.*;
			import com.flexShowcase.data.User;
			import com.flexShowcase.events.*;
			import com.flexShowcase.net.remote.FlexShowcaseServiceConfig;
			
			import flash.net.navigateToURL;
			import flash.net.URLRequest;
			
			import mx.collections.ArrayCollection;
			
			
			//////////////////////////////////////////////////
			//private variables
			
			[Bindable] public var tags:ArrayCollection;
			[Bindable] public var technologies:ArrayCollection;
			[Bindable] public var industries:ArrayCollection;
			[Bindable] public var flexShowcaseServiceConfig:FlexShowcaseServiceConfig;
			[Bindable] public var user:User;
			
			
			//////////////////////////////////////////////////
			//initialization
			
			private function creationCompleteHandler(event:Event):void {
				//tagsPanel.addEventListener(Event.CLOSE, tagsPanelCloseHandler);
				embedWidgetButton.addEventListener(MouseEvent.CLICK, embedWidgetClickHandler);
			}
			
			
			//////////////////////////////////////////////////
			//private functions
			/*
			private function toggleTagsPanel():void {
				switch (currentState) {
					case ScreenStates.TAGS_PANEL_CLOSED :
						currentState = ScreenStates.TAGS_PANEL_OPEN;
						break;
					case ScreenStates.TAGS_PANEL_OPEN :
						currentState = ScreenStates.TAGS_PANEL_CLOSED;
						break;
				}
			}
			
			private function closeTagsPanel():void {
				currentState = ScreenStates.TAGS_PANEL_CLOSED;
			}
			*/
			
			//////////////////////////////////////////////////
			//dispatch functions
			
			private function dispatchBackendToggleEvent():void {
				var navigationEvent:NavigationEvent = new NavigationEvent(NavigationEvent.BACKEND_TOGGLE);
				dispatchEvent(navigationEvent);
			}
			
			
			//////////////////////////////////////////////////
			//handler functions
			
			private function embedWidgetClickHandler(mouseEvent:MouseEvent):void {
				 var urlRequest:URLRequest = new URLRequest(flexShowcaseServiceConfig.widgetLink);
				 navigateToURL(urlRequest, "_blank");
			}
			
			/*
			private function featuredClickHandler(mouseEvent:MouseEvent):void {
				this.dispatchEvent(new NavigationEvent(NavigationEvent.FEATURED_SELECT))
			}
			
			private function browseClickHandler(mouseEvent:MouseEvent):void {
				this.dispatchEvent(new NavigationEvent(NavigationEvent.PROJECT_LIST_SELECT))
			}
			
			private function tagsButtonClickHandler(mouseEvent:MouseEvent):void {
				toggleTagsPanel();
			}
			*/
			/*
			private function loginButtonClickHandler(mouseEvent:MouseEvent):void {
				closeTagsPanel();
				
				dispatchBackendToggleEvent();
			}
			private function accountButtonClickHandler(mouseEvent:MouseEvent):void {
				closeTagsPanel();
				
				dispatchBackendToggleEvent();
			}
			
			private function tagsPanelCloseHandler(event:Event):void {
				closeTagsPanel();
				this.tagsButton.selected=false;
			}
			*/
			
		]]>
	</mx:Script>
	
	<!--
	<mx:states>
		<mx:State name="{ScreenStates.TAGS_PANEL_CLOSED}">
			<mx:SetProperty target="{tagsPanel}" name="y" value="-245" />
		</mx:State>
		<mx:State name="{ScreenStates.TAGS_PANEL_OPEN}">
			<mx:SetProperty target="{tagsPanel}" name="y" value="0" />
		</mx:State>
			
	</mx:states>
	-->
	<!--
	<mx:transitions>
		<mx:Transition id="openTransition" fromState="{ScreenStates.TAGS_PANEL_CLOSED}" toState="{ScreenStates.TAGS_PANEL_OPEN}">
			<mx:Parallel id="openParallel" targets="{[tagsPanel]}">
				<mx:Move duration="{AnimationFunctions.EXPONENTIAL_EASING_DURATION}" targets="{[tagsPanel]}" easingFunction="{AnimationFunctions.EXPONENTIAL_EASING_FUNCTION}" />
			</mx:Parallel>
		</mx:Transition>
		<mx:Transition id="closeTransition" fromState="{ScreenStates.TAGS_PANEL_OPEN}" toState="{ScreenStates.TAGS_PANEL_CLOSED}">
			<mx:Parallel id="closeParallel" targets="{[tagsPanel]}">
				<mx:Move duration="{AnimationFunctions.EXPONENTIAL_EASING_DURATION}" targets="{[tagsPanel]}" easingFunction="{AnimationFunctions.EXPONENTIAL_EASING_FUNCTION}" />
			</mx:Parallel>
		</mx:Transition>
	</mx:transitions>
	-->
	<mx:Image source="@Embed('/assets/images/mainHeader_bg.png')" />
	<mx:Image source="@Embed('/assets/images/mainHeader_tagsSearch_bg_small.png')" right="4" top="4"/>
	
	<!--<mx:CheckBox id="tagsButton" styleName="mainNavTagsChBx" right="177" top="-1" 
		toolTip="View applications by tag" buttonMode="true" click="tagsButtonClickHandler(event)"/>-->
	
	<components:MainNavSearchButton id="searchBut_mc" right="14" top="7"
		toolTip="Search for applications"/>
		
	<!--<mx:Button id="loginButton" styleName="blackButton" right="280" top="3" width="144" label="Login / Signup" toolTip="Manage your applications" buttonMode="true" visible="{!user.loggedIn}"  click="loginButtonClickHandler(event)" />
	<mx:Button id="accountButton" styleName="blackButton" right="280" top="3" width="144" label="My Account" toolTip="Manage your account" buttonMode="true" visible="{user.loggedIn}" click="accountButtonClickHandler(event)" />-->
	
	<!--<mx:Button id="embedWidgetButton" styleName="blackButton" right="424" top="3" width="144" 
		label="Embed Flex Widget" toolTip="Embed the Flex Widget in your Facebookpage" 
		buttonMode="true"/>-->
	<mx:Button id="embedWidgetButton" styleName="blackButton" right="155" top="3" width="144" 
		label="Embed Flex Widget" toolTip="Embed the Flex Widget in your Facebookpage" 
		buttonMode="true"/>
		
	<!--<mx:Canvas y="36" width="100%" height="240" horizontalScrollPolicy="off" verticalScrollPolicy="off" backgroundAlpha="0">
		<panels:TagsPanel id="tagsPanel" tags="{tags}" technologies="{technologies}" industries="{industries}" />
	</mx:Canvas>-->
	
</mx:Canvas>

⌨️ 快捷键说明

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