Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: f940a03185279306ce63268036ee824fb9ff3d6a
https://github.com/WebKit/WebKit/commit/f940a03185279306ce63268036ee824fb9ff3d6a
Author: Tyler Wilcock <[email protected]>
Date: 2026-09-29 (Tue, 29 Sep 2026)
Changed paths:
A
LayoutTests/http/tests/site-isolation/accessibility/client/absolute-position-iframe-in-scrolled-page-expected.txt
A
LayoutTests/http/tests/site-isolation/accessibility/client/absolute-position-iframe-in-scrolled-page.html
A
LayoutTests/http/tests/site-isolation/accessibility/client/absolute-position-nested-scrolled-iframes-expected.txt
A
LayoutTests/http/tests/site-isolation/accessibility/client/absolute-position-nested-scrolled-iframes.html
A
LayoutTests/http/tests/site-isolation/accessibility/client/absolute-position-scrolled-iframe-expected.txt
A
LayoutTests/http/tests/site-isolation/accessibility/client/absolute-position-scrolled-iframe-in-scrolled-page-expected.txt
A
LayoutTests/http/tests/site-isolation/accessibility/client/absolute-position-scrolled-iframe-in-scrolled-page.html
A
LayoutTests/http/tests/site-isolation/accessibility/client/absolute-position-scrolled-iframe.html
A
LayoutTests/http/tests/site-isolation/accessibility/resources/nested-scrolled-middle.html
A
LayoutTests/http/tests/site-isolation/accessibility/resources/scrolled-frame-with-text.html
M LayoutTests/platform/mac/TestExpectations
M Source/WebCore/page/FrameView.cpp
M Source/WebCore/page/FrameView.h
M Source/WebKit/UIProcess/WebPageProxy.cpp
M Source/WebKit/UIProcess/WebPageProxy.h
M Source/WebKit/WebProcess/WebPage/WebPage.cpp
M Source/WebKit/WebProcess/WebPage/WebPage.h
M Source/WebKit/WebProcess/WebPage/WebPage.messages.in
Log Message:
-----------
[Site Isolation] Remove usage of `convertRectToMainFrameCoordinates` in
`WebPageProxy::requestFrameScreenPosition`
https://bugs.webkit.org/show_bug.cgi?id=324501
rdar://187738555
Reviewed by Kiet Ho and Chris Fleizach.
requestFrameScreenPosition converts a unit rect anchored at a frame's content
origin into main
frame view coordinates, so the UI process can hand the frame's process a screen
position that
accessibility composes with content-space element rects.
It did that two different ways. The main frame sent a single
ContentsToRootViewRect to its own
process. Every other frame went through convertRectToMainFrameCoordinates,
which walks the frame
tree in the UI process and sends one ContentsToRootViewRect per isolation
boundary, each to the
parent's process. That chain re-enters contentsToView on an intermediate frame
once as a
LocalFrameView (in its own process) and again as a RemoteFrameView (in its
parent's process), so
the intermediate frame's scroll position is subtracted twice. With a page
scrolled to 400, a
cross-origin iframe at (100, 500) scrolled to 60, and a frame inside that one
at (30, 260) scrolled
to 200, the innermost frame was placed at (130, 40) instead of (130, 100).
Replace both branches with a single ContentsToMainFrameViewRect sent to the
frame's own process,
which converts across every boundary at once via
FrameView::contentsToMainFrameView. That drops one
IPC round trip per isolation boundary as well.
*
LayoutTests/http/tests/site-isolation/accessibility/client/absolute-position-iframe-in-scrolled-page-expected.txt:
Added.
*
LayoutTests/http/tests/site-isolation/accessibility/client/absolute-position-iframe-in-scrolled-page.html:
Added.
*
LayoutTests/http/tests/site-isolation/accessibility/client/absolute-position-nested-scrolled-iframes-expected.txt:
Added.
*
LayoutTests/http/tests/site-isolation/accessibility/client/absolute-position-nested-scrolled-iframes.html:
Added.
*
LayoutTests/http/tests/site-isolation/accessibility/client/absolute-position-scrolled-iframe-expected.txt:
Added.
*
LayoutTests/http/tests/site-isolation/accessibility/client/absolute-position-scrolled-iframe-in-scrolled-page-expected.txt:
Added.
*
LayoutTests/http/tests/site-isolation/accessibility/client/absolute-position-scrolled-iframe-in-scrolled-page.html:
Added.
*
LayoutTests/http/tests/site-isolation/accessibility/client/absolute-position-scrolled-iframe.html:
Added.
*
LayoutTests/http/tests/site-isolation/accessibility/resources/nested-scrolled-middle.html:
Added.
*
LayoutTests/http/tests/site-isolation/accessibility/resources/scrolled-frame-with-text.html:
Added.
* LayoutTests/platform/mac/TestExpectations:
* Source/WebCore/page/FrameView.cpp:
(WebCore::FrameView::contentsToMainFrameView const):
* Source/WebCore/page/FrameView.h:
* Source/WebKit/UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::requestFrameScreenPosition):
(WebKit::WebPageProxy::applyAccessibilityFrameScreenPosition):
* Source/WebKit/UIProcess/WebPageProxy.h:
* Source/WebKit/WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::contentsToMainFrameViewRect):
* Source/WebKit/WebProcess/WebPage/WebPage.h:
* Source/WebKit/WebProcess/WebPage/WebPage.messages.in:
Canonical link: https://commits.webkit.org/322157@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications