Closed Bug 1666435 Opened 6 years ago Closed 3 years ago

[wpt-sync] Sync PR 25667 - Ensure visibilityState gets updated before pagehide & pageshow

Categories

(Core :: DOM: Core & HTML, task, P4)

task

Tracking

()

RESOLVED INVALID

People

(Reporter: wpt-sync, Unassigned)

References

()

Details

(Whiteboard: [wptsync downstream])

Sync web-platform-tests PR 25667 into mozilla-central (this bug is closed when the sync is complete).

PR: https://github.com/web-platform-tests/wpt/pull/25667
Details from upstream follow.

b'Rakina Zata Amni <rakina@chromium.org>' wrote:

Ensure visibilityState gets updated before pagehide & pageshow

Currently when unloading a document, we would fire pagehide before
updating ≈ and firing visibilitychange. This CL swaps this
ordering so that we would fire visibilitychange before pagehide per the
spec change at https://github.com/whatwg/html/pull/5928.

This CL also ensures visibilitychange fires before pageshow to follow
the spec at https://html.spec.whatwg.org/multipage/browsing-the-web.html#session-history-document-visibility-change-steps

Bug: 1130950
Change-Id: Iaa23d14fe7b22b16af661b573a5f617530dc2303

Reviewed-on: https://chromium-review.googlesource.com/2422109
WPT-Export-Revision: 1163da0e5d34b1359dd5ad9e8600795dacfda1e9

Component: web-platform-tests → DOM: Core & HTML
Product: Testing → Core
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → INVALID
You need to log in before you can comment on or make changes to this bug.