http://game.play-cs.com is a website to play counterstrike in the browser. It's super buggy in Safari: - It doesn't have sound - Fullscreen doesn't work properly. Safari is constantly entering/exiting full screen every second or so.
(In reply to Saam Barati from comment #0) > http://game.play-cs.com is a website to play counterstrike in the browser. > It's super buggy in Safari: > - It doesn't have sound > - Fullscreen doesn't work properly. Safari is constantly entering/exiting > full screen every second or so. There are lots of bugs around full screen. It seems to work a bit better if you full screen Safari itself using native macOS UI. But if you press the fullscreen button in the game without full screening the macOS app, that's when I was seeing the above bug. Now, I just encountered a different bug. If I fullscreen in the macOS Safari window UI, and then press the full screen button in the game, sometimes it'll kick me out from the desktop that Safari is full screened in, and take me back to the desktop that doesn't have Safari in it.
<rdar://problem/104984915>
I’m seeing this in Safari 16.3
Saam says: "It worked properly my first time through, but playing around with entering/exiting made madness ensue. Repro might not be 100%, though whatever it is my machine seems to hit it every time now. I quit and relaunched, and that didn’t fix it."
Created attachment 465694 [details] Reduced testcase Seems like a visibilitychange event is triggered when entering fullscreen, which triggers an event listener on the page that exits fullscreen. Here is a reduced testcase.
*** Bug 262939 has been marked as a duplicate of this bug. ***
Re-titling to make this about the fullscreen issue. Let's track the audio issue in a new bug.
Pull request: https://github.com/WebKit/WebKit/pull/18883
Hi Saam! Aside from Andy's PR, why is play-cs.com exiting fullscreen when visibility changes? That means users can't switch spaces in Mac fullscreen without their game exiting. That's super annoying!
For the audio issue, if play-cs.com makes use of WebAudio, this commit may interest you: https://commits.webkit.org/268047@main
Filed https://bugs.webkit.org/show_bug.cgi?id=262963 to track the audio issue.
Committed 269150@main (7e8c765bf94d): <https://commits.webkit.org/269150@main> Reviewed commits have been landed. Closing PR #18883 and removing active labels.