Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 66ba699e69102c7efbd92303666a45a23ab74bb2
https://github.com/WebKit/WebKit/commit/66ba699e69102c7efbd92303666a45a23ab74bb2
Author: Jer Noble <[email protected]>
Date: 2024-03-14 (Thu, 14 Mar 2024)
Changed paths:
M LayoutTests/fast/viewport/ios/full-screen-safe-area-insets-expected.txt
M LayoutTests/fast/viewport/ios/full-screen-safe-area-insets.html
A LayoutTests/fast/viewport/ios/resources/no-viewport.html
M Source/WebKit/WebProcess/FullScreen/WebFullScreenManager.cpp
M Source/WebKit/WebProcess/WebPage/WebPage.cpp
M Source/WebKit/WebProcess/WebPage/WebPage.h
M Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm
Log Message:
-----------
[iOS] Entering fullscreen from iframe without explicit viewport results in
badly cropped video
https://bugs.webkit.org/show_bug.cgi?id=270909
rdar://123725878
Reviewed by Abrar Rahman Protyasha.
In 270199@main, support was added for using the viewport settings from the
outermost fullscreen
document, rather than the top document. This allowed an <iframe> whose contents
specified a
viewport-fit=cover behavior to work within a hosting document without that
viewport setting.
However, for an <iframe> whose contents did not specify a viewport at all, it
would receive
the default desktop viewport, which is 980px wide. This, combined with the iOS
fullscreen
behavior of blocking zoom, meant that the fullscreen viewport would be much,
much larger than
the physical viewport.
When entering or exiting fullscreen mode, notify the WebPage, and reset the
default viewport
such that in fullscreen the web page will receive the "native" viewport rather
than the "desktop"
one by default. This requires storing the results of didReceiveMobileDocType(),
so that it
can be re-used after page load.
* Source/WebKit/WebProcess/FullScreen/WebFullScreenManager.cpp:
(WebKit::WebFullScreenManager::willEnterFullScreen):
(WebKit::WebFullScreenManager::didExitFullScreen):
* Source/WebKit/WebProcess/WebPage/WebPage.cpp:
(WebKit::WebPage::isInFullscreenChanged):
* Source/WebKit/WebProcess/WebPage/WebPage.h:
* Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::didReceiveMobileDocType):
(WebKit::WebPage::resetViewportDefaultConfiguration):
Canonical link: https://commits.webkit.org/276138@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