- From: Mason Freed <notifications@github.com>
- Date: Wed, 03 May 2023 11:42:34 -0700
- To: whatwg/fullscreen <fullscreen@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
- Message-ID: <whatwg/fullscreen/pull/223/c1533527350@github.com>
> For testing, a think a single new test would cover this PR. It should have two sibling divs, A and B. Request fullscreen once per click in order A-B-A and assert that all requests succeed but the last is a no-op and that `document.fullscreenElement` is still B. Bonus points for exiting fullscreen once and asserting that `document.fullscreenElement` is then A again, and then once more to make `document.fullscreenElement` null. So I wrote [a test](https://github.com/web-platform-tests/wpt/pull/39828) for this, but I'm getting a bit more concerned about the behavior. As-is, Chromium fails this test, because the current behavior is that A is ([manually](https://source.chromium.org/chromium/chromium/src/+/main:third_party/blink/renderer/core/fullscreen/fullscreen.cc;l=203;drc=4a24affd324ec742bfb061cda42e459308e36161)) popped to the top of the top layer stack when `A.requestFullscreen()` is called the second time. Gecko and WebKit both fail before that point (at `B.requestFullscreen()`) because of the descendant check. I'm still supportive of changing this, but I'm worried about compat. Perhaps, if there's agreement with this direction (@annevk @emilio - thoughts?) then I can add a use counter for this situation and see where we stand? The other way to go is to keep Chromium's current behavior of popping A back to the top on the second call to `requestFullscreen()`. This is definitely web compatible, and I could see an argument for this being useful for developers. -- Reply to this email directly or view it on GitHub: https://github.com/whatwg/fullscreen/pull/223#issuecomment-1533527350 You are receiving this because you are subscribed to this thread. Message ID: <whatwg/fullscreen/pull/223/c1533527350@github.com>
Received on Wednesday, 3 May 2023 18:42:39 UTC