How to pause flash application in browser?

白昼怎懂夜的黑 提交于 2020-01-16 01:00:08

问题


How to pause flash application in browser if there isn't any buttons that would allow it ?


回答1:


Well, there is a website, there is a swf file, i want to pause it.

Do you have access to these files and their source? Is it on the same domain?

Anyway, the previous two answers suggested wrapping the swf with another Flash application and then setting the framerate to 0. That's not accurate, because the minimum framerate you can set is 0.01. Flash code is built around the framerate, it makes sense. http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/display/Stage.html#frameRate

If you have access to the original files you want to pause, the proper way to accomplish this would be through ExternalInterface

http://help.adobe.com/en_US/FlashPlatform/reference/actionscript/3/flash/external/ExternalInterface.html

http://www.viget.com/inspire/bi-directional-actionscript-javascript-communication/




回答2:


yes by adding this stage.frameRate = 0;

pause flash

Pause-Game-Using-stage-framerate

pause using javascript




回答3:


Your question is a little vague, I'm a little confused at exactly what you want. I did find something that MIGHT help in this question. But here's what I saw that might help you out:

Embed an swf, that'll load the game. Then you'll be able to have some control, because the loaded SWF is running in the same instance as the loading SWF. For most games, it should suffice setting the frame rate to 0.

So setting the frame rate to 0 is essentially pausing it... But I would be able to provide a more detailed answer if you clarify your question a bit more.



来源:https://stackoverflow.com/questions/9619276/how-to-pause-flash-application-in-browser

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!