开发者

Handling event inside loaded swf in MATE

开发者 https://www.devze.com 2023-04-04 03:40 出处:网络
Can I handle an event inside a loaded swf file(using swf loader) using MAT开发者_运维百科E when my main application fires the event ? i want to make a remote service call based on the data i get from

Can I handle an event inside a loaded swf file(using swf loader) using MAT开发者_运维百科E when my main application fires the event ? i want to make a remote service call based on the data i get from the main applications event , and then populate my loaded swf .


It really depends how things are loaded. By default, no, Mate cannot do this because of the way events work; they go up the display list, and not down to the children.

The only way I can think of doing this is to wait for the swf to finish loading and then listen for the even on the root application (in Flex do FlexGlobals.topLevelApplication.addEventListener). However, this is a huge hack and shouldn't be done. The real problem here is how your application is architected, and you should look into how to solve the issue at its core.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号