1

Just a few quick questions from me:

What is the best way to inserting a Flash SWF file into a flex, that will enable me to have it start from frame 0 on reentry of that framework? Would this be States, Viewstack?

Is there a way of using forward and back buttons to navigate through displaying a set of States rather than selecting certain objects that will then change the state onscreen?

Is there some code anywhere that can show this?

Also buttons in Flash, is there a problem of them being selectable when they are displayed in Flash?

TIA - Regards

J

4

1 回答 1

1

如果您使用 Viewstack,则可以将 SWF 放入容器中,例如 Canvas,然后执行类似的操作

<mx:ViewStack>
   <mx:Canvas show="(mySWFA.content as MovieClip).gotoAndPlay(0);">
      <mx:SWFLoader id="mySWFA" source="mySWFA.swf"/>
   </mx:Canvas>
   <mx:Canvas show="(mySWFB.content as MovieClip).gotoAndPlay(0);">
      <mx:SWFLoader id="mySWFB" source="mySWFB.swf"/>
   </mx:Canvas>
</mx:ViewStack>

我没有对此进行测试,我对 .content 部分进行了一些猜测,但基本思想是 Viewstack 将在堆栈索引更改时触发 show 事件。这会给你一个钩子来倒带你的瑞士法郎。

此外,可以通过项目属性->Flex 编译器->浏览器集成将 Viewstack 设置为服从浏览器的前进和后退按钮。一旦打开,它应该会自动工作。

于 2008-10-31T02:10:49.700 回答