フレックスのデスクトップアプリケーションを開発しています.2つの画面があります(つまり、mxml windowedapplication).i 1つの画面から別の画面(mxmlファイルから別の画面)にナビゲートしたいのですが。flex(flash builder 4.6)を使用してデスクトップアプリケーションのクリック機能を使用して画面間をナビゲートする方法はありますか?
0
A
答えて
0
あなただけ
プロジェクトStageOrientationEventクラスに
パッケージflash.events {
を追加するいくつかのトリックを行う必要があり、デスクトップアプリケーションでViewNavigatorのを使用することができますpublic class StageOrientationEvent extends Event { static public const ORIENTATION_CHANGE:String = "orientationChange"; static public const ORIENTATION_CHANGING:String = "orientationChanging"; public function StageOrientationEvent(type:String, bubbles:Boolean=false, cancelable:Boolean=false) { super(type, bubbles, cancelable); } }
}
ViewNavigatorの
< sのための新しいスキン作成:スキンのxmlns:FX = "http://ns.adobe.com/mxml/2009" のxmlns:S = "ライブラリ://ns.adobe.com/をフレックス/スパーク」 のxmlns:FB = "http://ns.adobe.com/flashbuilder/2009" alpha.disabled = "0.5">
<fx:Metadata>[HostComponent("spark.components.ViewNavigator")]</fx:Metadata> <fx:Script fb:purpose="styling"> <![CDATA[ override protected function updateDisplayList(unscaledWidth:Number, unscaledHeight:Number) : void { super.updateDisplayList(unscaledWidth, unscaledHeight); } ]]> </fx:Script> <s:states> <s:State name="normal" /> <s:State name="disabled" /> <s:State name="landscape" /> <s:State name="portrait" /> <s:State name="landscapeAndOverlay" /> <s:State name="portraitAndOverlay" /> </s:states> <s:Group id="contentGroup" left="0" right="0" top="0" bottom="0" minWidth="0" minHeight="0"> <s:layout> <s:BasicLayout/> </s:layout> </s:Group>
</sで皮膚>
あなたのプロジェクトにmobilecomponents.swcを追加します(私の場合はC:\ Program Files \ Adobe \ Adobe Flash Builder 4.6 \ sdks \ 4.6.0 \ frameworks \ libです) Sの\携帯用の\ mobilecomponents.swc)
は
直接ViewNavigatorのインスタンスにViewNavigatorのに新しいViewNavigatorのスキン(ステップ2)を割り当てる:
<s:ViewNavigator skinClass="path.to.skin.ViewNavigatorSkin"/>
またはグローバルCSSの
s|ViewNavigator{
skinClass: ClassReference("path.to.skin.ViewNavigatorSkin");
}
1
返信いただきありがとうございます..正確には必要ありません...私は1つの画面からanotheへのナビゲーションをしたいrスクリーン(1つのmxmlファイルから別のmxmlファイルへ).asフレックスでのモバイル(navigator.push view())のために使用します..このように –
@francisdcunhaモバイルアプリケーションをWebに変換するとき。私はモバイルナビゲータからStatesに切り替えました。 – JeffryHouser