[webkit-changes] [WebKit/WebKit] 524ce3: REGRESSION (290178 at main): [macOS] imported/w3c/web...
Wenson Hsieh
noreply at github.com
Thu Feb 13 15:54:47 PST 2025
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 524ce3a2495d64566e65f482740813b785095337
https://github.com/WebKit/WebKit/commit/524ce3a2495d64566e65f482740813b785095337
Author: Wenson Hsieh <wenson_hsieh at apple.com>
Date: 2025-02-13 (Thu, 13 Feb 2025)
Changed paths:
M Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp
Log Message:
-----------
REGRESSION (290178 at main): [macOS] imported/w3c/web-platform-tests/css/css-view-transitions/dialog-in-rtl-iframe.html fails
https://bugs.webkit.org/show_bug.cgi?id=287585
rdar://144732945
Reviewed by Abrar Rahman Protyasha.
Prior to 290178 at main, logic in `AsyncScrollingCoordinator::reconcileScrollingState` only accounted
for the top content inset when determining the position for the inset clip layer (i.e. the
`RenderLayerCompositor`'s `clipLayer`). Importantly, this preserved the previous `x` value of the
`insetClipLayer`'s position:
```
positionForInsetClipLayer = FloatPoint(insetClipLayer->position().x(), LocalFrameView::yPositionForInsetClipLayer(scrollPosition, obscuredContentInsets.top()));
```
...after 290178 at main, both axes are now accounted for when computing the inset clip layer position:
```
positionForInsetClipLayer = LocalFrameView::positionForInsetClipLayer(scrollPosition, obscuredContentInsets);
```
...however, this introduces a subtle issue where, if the inset clip layer position's `x` was
nonzero, it would be overridden by the value of the left content inset (in the case of this test,
0). Before reconciling scrolling state, the position of the inset clip layer is previously computed
by the following method:
```
FloatPoint RenderLayerCompositor::positionForClipLayer() const
{
auto& frameView = m_renderView.frameView();
auto clipLayerPosition = LocalFrameView::positionForInsetClipLayer(frameView.scrollPosition(), frameView.obscuredContentInsets());
return FloatPoint(frameView.insetForLeftScrollbarSpace() + clipLayerPosition.x(), clipLayerPosition.y());
}
```
Note that this importantly accounts for `frameView.insetForLeftScrollbarSpace()`, which is nonzero
in the case where there's an RTL scrollbar. Fix this failing test case by (re-)teaching
`reconcileScrollingState` to account for the left scrollbar inset when computing the inset clip
layer position, such that it's consistent with `RenderLayerCompositor`.
* Source/WebCore/page/scrolling/AsyncScrollingCoordinator.cpp:
(WebCore::AsyncScrollingCoordinator::reconcileScrollingState):
Canonical link: https://commits.webkit.org/290373@main
To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications
More information about the webkit-changes
mailing list