swfloader

Flex: Impossible to resize the external loaded SWF's content

我与影子孤独终老i 提交于 2019-12-01 06:26:50
I have an application where I try to load an external SWF. So, we have: My application: The Stage's dimensions are 768x1280. ScaleMode = EXACT_FIT. External SWF: It's another application where its stage is: 800x600. ScaleMode = EXACT_FIT. The problem is that the external SWF does not modify its size although I apply "scaleX, scaleY", change its width and so on. I also tried to insert it into a Canvas container (as "How to resize an external SWF to fit into a container?" ) but it didn't solve my problem. The interesting piece of code is when the external SWF is loaded by my application: private

How to raise an event from a SWF in a SWFLoader to a parent Flex application?

血红的双手。 提交于 2019-11-28 10:35:51
How can I raise an event from a SWF file loaded into a Flex application (using SWFLoader)? I want to be able to detect a) when a button is pressed b) when the animation ends You'll need to do 2 things: Dispatch an event from the loaded swf. Make sure the event bubbles if you sent it from nested views. Bubbling can be set through the bubbles property of the event. Listen to the event from your main application. I think you should be able to do that on the content property of the SWFLoader instance. mySWFLoader.content.addEventListener("myEvent", myEventHandler); I took a lazier approach for

How to raise an event from a SWF in a SWFLoader to a parent Flex application?

大城市里の小女人 提交于 2019-11-27 03:40:38
问题 How can I raise an event from a SWF file loaded into a Flex application (using SWFLoader)? I want to be able to detect a) when a button is pressed b) when the animation ends 回答1: You'll need to do 2 things: Dispatch an event from the loaded swf. Make sure the event bubbles if you sent it from nested views. Bubbling can be set through the bubbles property of the event. Listen to the event from your main application. I think you should be able to do that on the content property of the SWFLoader