[webkit-changes] [WebKit/WebKit] ecf63c: [Debug] ASSERTION FAILED: m_phase == ViewTransitio...
Vitaly Dyachkov
noreply at github.com
Tue Dec 12 17:22:10 PST 2023
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: ecf63ceef8cf9afc28b7bbbd1eb7ad0582929542
https://github.com/WebKit/WebKit/commit/ecf63ceef8cf9afc28b7bbbd1eb7ad0582929542
Author: Vitaly Dyachkov <vitaly at igalia.com>
Date: 2023-12-12 (Tue, 12 Dec 2023)
Changed paths:
M LayoutTests/platform/glib/TestExpectations
M LayoutTests/platform/mac/TestExpectations
M Source/WebCore/dom/ViewTransition.cpp
M Source/WebCore/dom/ViewTransition.h
Log Message:
-----------
[Debug] ASSERTION FAILED: m_phase == ViewTransitionPhase::Done || m_phase == ViewTransitionPhase::PendingCapture
https://bugs.webkit.org/show_bug.cgi?id=265868
Reviewed by Tim Nguyen.
During each invocation of `Page::updateRendering()`, the `Document`
triggers the `setupViewTransition()` method of `m_activeViewTransition`
when it's in the `ViewTransitionPhase::PendingCapture` phase.
The `ViewTransition` first updates its state within the
`callUpdateCallback()` method, which is executed asynchronously.
This can lead to a situation where the active `ViewTransition` has been
set up, but its state remains `ViewTransitionPhase::PendingCapture`
when the `Document` checks it.
In such cases, the `Document` may call `setupViewTransition()` more
than once.
To address this issue, this patch introduces a
`ViewTransitionPhase::Capturing` state, indicating that the transition
setup is complete, but the callback has not been called yet.
Note that this phase is not part of the spec [1].
1. https://drafts.csswg.org/css-view-transitions/#viewtransition-phase
* Source/WebCore/dom/ViewTransition.cpp:
(WebCore::ViewTransition::callUpdateCallback):
(WebCore::ViewTransition::setupViewTransition):
* Source/WebCore/dom/ViewTransition.h:
Canonical link: https://commits.webkit.org/271959@main
More information about the webkit-changes
mailing list