Is there a way to use the HTML5 Gamepad API with multiple windows or tabs in Firefox?

試著忘記壹切 提交于 2020-01-01 15:03:23

问题


I'm designing an app that utilizes input from a gamepad using the HTML5 Gamepad API. I have the app working in both Firefox and Chrome, however Firefox does not seem to allow a second Window or Tab to access the gamepad after a previous tab has accessed it. I don't need both to access the api at the same time, I only need one to be able to access the api after the other. Chrome does not have this problem. I also tested using html5gamepad.com with the same results. Does anyone have a way to release the gamepad from one window when it loses focus so it is available to another window? My customer will be using Firefox. Thanks.

来源:https://stackoverflow.com/questions/54154170/is-there-a-way-to-use-the-html5-gamepad-api-with-multiple-windows-or-tabs-in-fir

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