Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: eed2135df5c13f8489aab2b6a7bd7ad21e191c2b
https://github.com/WebKit/WebKit/commit/eed2135df5c13f8489aab2b6a7bd7ad21e191c2b
Author: Wenson Hsieh <[email protected]>
Date: 2025-05-30 (Fri, 30 May 2025)
Changed paths:
M Source/WebKit/UIProcess/API/Cocoa/WKWebView.mm
M Source/WebKit/UIProcess/API/ios/WKWebViewIOS.mm
M Source/WebKit/UIProcess/ios/UIKitUtilities.h
M Source/WebKit/UIProcess/ios/UIKitUtilities.mm
Log Message:
-----------
[iOS] Refresh control is not visible when there is fixed top element on the
page
https://bugs.webkit.org/show_bug.cgi?id=293791
rdar://149399460
Reviewed by Richard Robinson.
The fixed color extension view is currently inserted into the view hierarchy
after the content view.
This allows the extension view to properly obscure the part of the page above
viewport-constrained
objects aligned to edges of the viewport. However, it also means that when
scrolling up beyond the
top extent of the scroll view, it also covers the refresh control (e.g. spinner
in Safari) of the
scroll view.
To mitigate this (while allowing fixed color extension views to cover the page
content while
scrolling past the top), we teach the top color extension view to either:
1. Reinsert itself before the refresh control in the scroll view's subview
array when the page is
rubber-banding against the top edge.
2. Reinsert itself after the content view when the page is either at or
scrolled past the top edge.
* Source/WebKit/UIProcess/API/Cocoa/WKWebView.mm:
(-[WKWebView _updateFixedColorExtensionViews]):
* Source/WebKit/UIProcess/API/ios/WKWebViewIOS.mm:
(-[WKWebView _reinsertTopFixedColorExtensionViewIfNeeded]):
Ensure that the top fixed color extension view is inserted in the right
position, in the array of
subviews below the scroller.
(-[WKWebView scrollViewDidScroll:]):
See above.
* Source/WebKit/UIProcess/ios/UIKitUtilities.h:
* Source/WebKit/UIProcess/ios/UIKitUtilities.mm:
(-[UIScrollView _wk_isScrolledBeyondTopExtent]):
Add a category helper method to determine whether or not the scroll view is
rubber-banding against
the top edge.
Canonical link: https://commits.webkit.org/295613@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