Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 8ac8e902cceaddc21445b0837575fa16a494d5a1
https://github.com/WebKit/WebKit/commit/8ac8e902cceaddc21445b0837575fa16a494d5a1
Author: Wenson Hsieh <[email protected]>
Date: 2025-08-08 (Fri, 08 Aug 2025)
Changed paths:
M Source/WebKit/Shared/WebPageCreationParameters.h
M Source/WebKit/Shared/WebPageCreationParameters.serialization.in
M Source/WebKit/UIProcess/API/Cocoa/WKWebViewPrivate.h
M Source/WebKit/UIProcess/API/mac/WKWebViewMac.mm
M Source/WebKit/UIProcess/Inspector/mac/WKInspectorViewController.mm
M Source/WebKit/UIProcess/WebPageProxy.cpp
M Source/WebKit/UIProcess/WebPageProxy.h
M Source/WebKit/UIProcess/mac/WebPageProxyMac.mm
M Source/WebKit/UIProcess/mac/WebViewImpl.mm
M Source/WebKit/WebProcess/WebPage/Cocoa/WebPageCocoa.mm
M Source/WebKit/WebProcess/WebPage/WebPage.cpp
M Source/WebKit/WebProcess/WebPage/WebPage.h
M Source/WebKit/WebProcess/WebPage/WebPage.messages.in
M Tools/TestWebKitAPI/Tests/WebKitCocoa/ObscuredContentInsets.mm
Log Message:
-----------
[Liquid Glass] [macOS] Add a way to extend the height of the scroll pocket
https://bugs.webkit.org/show_bug.cgi?id=297106
rdar://157815756
Reviewed by Aditya Keerthi.
Add a new macOS-specific property,
`-_setOverflowHeightForTopScrollEdgeEffect:`, to allow Safari to
extend the height of the web view's scroll pocket upwards by a specified
amount. See below for more
details.
* Source/WebKit/Shared/WebPageCreationParameters.h:
* Source/WebKit/Shared/WebPageCreationParameters.serialization.in:
Add `overflowHeightForTopScrollEdgeEffect` to WebPage creation parameters, so
that newly created web
views will start with the correct height.
* Source/WebKit/UIProcess/API/Cocoa/WKWebViewPrivate.h:
* Source/WebKit/UIProcess/API/mac/WKWebViewMac.mm:
(-[WKWebView scrollViewDrawsMagicPocket]):
Return true if either the top obscured content inset or the additional overflow
height is nonzero.
(-[WKWebView _overflowHeightForTopScrollEdgeEffect]):
(-[WKWebView _setOverflowHeightForTopScrollEdgeEffect:]):
* Source/WebKit/UIProcess/Inspector/mac/WKInspectorViewController.mm:
(-[WKInspectorViewController didAttachOrDetach]):
Also propagate this SPI over to the attached inspector web view, so that docked
inspector views will
also get the extra pocket height.
* Source/WebKit/UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::creationParameters):
* Source/WebKit/UIProcess/WebPageProxy.h:
* Source/WebKit/UIProcess/mac/WebPageProxyMac.mm:
(WebKit::WebPageProxy::setOverflowHeightForTopScrollEdgeEffect):
* Source/WebKit/UIProcess/mac/WebViewImpl.mm:
(WebKit::WebViewImpl::updateScrollPocket):
* Source/WebKit/WebProcess/WebPage/Cocoa/WebPageCocoa.mm:
(WebKit::WebPage::sidesRequiringFixedContainerEdges const):
Make sure we sample for the top fixed container, in the case where a nonzero
overflow top pocket
height is set.
* Source/WebKit/WebProcess/WebPage/WebPage.cpp:
* Source/WebKit/WebProcess/WebPage/WebPage.h:
* Source/WebKit/WebProcess/WebPage/WebPage.messages.in:
* Tools/TestWebKitAPI/Tests/WebKitCocoa/ObscuredContentInsets.mm:
(TestWebKitAPI::TEST(ObscuredContentInsets,
OverflowHeightForTopScrollEdgeEffect)):
Add an API test to exercise this new property.
Canonical link: https://commits.webkit.org/298394@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes