REGRESSION(298142@main): Web content may be temporarily offset during Safari View Controller presentation#49081
Merged
webkit-commit-queue merged 1 commit intoWebKit:mainfrom Aug 8, 2025
Conversation
Collaborator
|
EWS run on previous version of this PR (hash 2cec373) Details |
whsieh
approved these changes
Aug 7, 2025
whsieh
reviewed
Aug 7, 2025
Member
Author
|
Thank you for the review! iOS API bot is green |
Collaborator
|
EWS run on current version of this PR (hash dcff8d1) Details
|
… Safari View Controller presentation https://bugs.webkit.org/show_bug.cgi?id=297076 rdar://157669095 Reviewed by Wenson Hsieh. After 298142@main, we notice that the initial web content presented when an SFSafariViewController sheet is brought up can be temporarily offset. Logging suggests this can happen when we're in the middle of a live resize, so _shouldDeferGeometryUpdates is respected and overridden layout parameter updates are not dispatched on the first layer tree transaction after obscured insets are set on the web view. To work around this issue, we introduce a small escape hatch, where even if _shouldDeferGeometryUpdates holds, we update the layout size if (a) the web view lives in a Safari view service and (b) the window scene is not being interactively resized. We add a couple of API tests as coverage for 298142@main, just to verify that these geometry updates can be made during animated/live resizes without hanging the UI process. * Source/WebKit/UIProcess/API/ios/WKWebViewIOS.mm: (-[WKWebView _didCommitLayerTree:]): * Tools/TestWebKitAPI/Tests/WebKitCocoa/AnimatedResize.mm: (TEST(AnimatedResize, ChangingWebViewGeometryDuringLiveResizeDoesNotHang)): (TEST(AnimatedResize, ChangingWebViewGeometryDuringAnimatedResizeDoesNotHang)): Canonical link: https://commits.webkit.org/298370@main
dcff8d1 to
30fd586
Compare
Collaborator
|
Committed 298370@main (30fd586): https://commits.webkit.org/298370@main Reviewed commits have been landed. Closing PR #49081 and removing active labels. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
30fd586
dcff8d1
🛠 wpe🛠 win🧪 wpe-wk2🧪 win-tests🧪 ios-wk2🧪 api-mac🧪 api-wpe🧪 ios-wk2-wpt🧪 mac-wk1🧪 api-ios🧪 mac-wk2🛠 gtk🛠 vision🧪 mac-AS-debug-wk2🧪 gtk-wk2🛠 vision-sim🧪 mac-wk2-stress🧪 api-gtk🧪 mac-intel-wk2🛠 playstation🛠 mac-safer-cpp🛠 tv-sim🛠 watch🛠 watch-sim