Flash AS3全屏问题:屏幕恢复正常模式

发布于 2024-11-08 19:37:37 字数 303 浏览 2 评论 0原文

我有一个全屏按钮,单击该按钮即可工作。然而,几秒钟后,Flash 会自动退出全屏模式并恢复到正常模式。我正在浏览器中运行它。我尝试将全屏事件处理程序中的所有代码剥离到此(我删除了显示状态之间的切换):

    private function fullScreenHandler( event:MouseEvent ):void
    {           
        stage.displayState=StageDisplayState.FULL_SCREEN;

    }

它仍然在发生。有人见过这个吗?

I've got a fullscreen button which, when clicked, works. However, after a few seconds, Flash automatically exits full-screen mode and reverts to normal mode. I'm running this in the browser. I tried stripping all the code in the fullScreen event handler down to this (I removed toggling between displayStates):

    private function fullScreenHandler( event:MouseEvent ):void
    {           
        stage.displayState=StageDisplayState.FULL_SCREEN;

    }

It's still happening. Has anyone seen this before?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

陌路黄昏 2024-11-15 19:37:37

每次都在相同的时间后退出全屏吗?这可能是一些愚蠢的事情,比如计算机进入睡眠状态。我从未经历过 Flash 播放器在这种情况下独立退出全屏,但我可以想象,因为它在改变事物的浏览器中。

因此,如果可以的话,我建议尝试从 Flash 播放器而不是浏览器运行它。这应该告诉您您的应用程序或浏览器是否有问题。

同样的道理,在不同的浏览器上尝试一下。因为我认为它相当便携,所以你也应该考虑在不同的物理计算机上尝试它。

Does it exit fullscreen after the same amount of time every time? It could be something silly like the computer going to sleep then. I've never experienced flash player standalone exiting fullscreen in such a case but I could imagine because its in a browser that changes things.

So I'd suggest to try running it from the flash player as opposed to the browser if you can. This should tell you if it is something wrong with your app or the browser.

On the same note try it on different browsers. Since I imagine its fairly portable you should also consider trying it on different physical computers.

九公里浅绿 2024-11-15 19:37:37

尝试在全屏退出时挂起函数,插入一些会引发异常的代码(例如尝试调用 null 的某些方法,这是 Haxe/Flash 中最简单的方法)并查看异常的堆栈跟踪。您将看到导致退出全屏的原因。

Try to hang function on full screen exiting, insert some code which will throw an exception (e.g. try to call some method of a null, it's the simpliest way in Haxe/Flash) and see stack trace of exception. You'll see what causes exit from full-screen.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文