[Fullscreen] Page sometimes ends up with an incorrect zoom level after entering fulls...
authorjer.noble@apple.com <jer.noble@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 21 Jun 2018 21:23:12 +0000 (21:23 +0000)
committerjer.noble@apple.com <jer.noble@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 21 Jun 2018 21:23:12 +0000 (21:23 +0000)
commitcfc98cf6667dbf96283420657c4d959ac9bc95e3
treef4577da9b6c29412855571619da998c22b61dd62
parent178a501a61b46e199da95fb6f51be7e88bfa0203
[Fullscreen] Page sometimes ends up with an incorrect zoom level after entering fullscreen
https://bugs.webkit.org/show_bug.cgi?id=186822

Reviewed by Simon Fraser.

Source/WebCore:

* dom/Document.cpp:
(WebCore::Document::setOverrideViewportArguments):
(WebCore::Document::updateViewportArguments):
* dom/Document.h:

Source/WebKit:

Set the minimum zoom, maximum zoom, zoom bouncing, and user scalability settings of the
WKWebView's UIScrollView upon entering fullscreen, and restore those same settings upon
exit. Override the viewport arguments upon entering fullscreen, restore them upon exit.

* Platform/IPC/ArgumentCoder.h:
* Shared/WebCoreArgumentCoders.cpp:
(IPC::ArgumentCoder<ViewportArguments>::decode):
* Shared/WebCoreArgumentCoders.h:
* UIProcess/WebPageProxy.h:
(WebKit::WebPageProxy::forceAlwaysUserScalable const):
* UIProcess/ios/WebPageProxyIOS.mm:
(WebKit::WebPageProxy::setOverrideViewportArguments):
* UIProcess/ios/fullscreen/WKFullScreenWindowControllerIOS.mm:
(WebKit::WKWebViewState::applyTo):
(WebKit::WKWebViewState::store):
(-[WKFullScreenWindowController enterFullScreen]):
(-[WKFullScreenWindowController beganExitFullScreenWithInitialFrame:finalFrame:]):
* WebProcess/WebPage/WebPage.h:
(WebKit::WebPage::forceAlwaysUserScalable const):
* WebProcess/WebPage/WebPage.messages.in:
* WebProcess/WebPage/ios/WebPageIOS.mm:
(WebKit::WebPage::setOverrideViewportArguments):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@233059 268f45cc-cd09-0410-ab3c-d52691b4dbfc
13 files changed:
Source/WebCore/ChangeLog
Source/WebCore/dom/Document.cpp
Source/WebCore/dom/Document.h
Source/WebKit/ChangeLog
Source/WebKit/Platform/IPC/ArgumentCoder.h
Source/WebKit/Shared/WebCoreArgumentCoders.cpp
Source/WebKit/Shared/WebCoreArgumentCoders.h
Source/WebKit/UIProcess/WebPageProxy.h
Source/WebKit/UIProcess/ios/WebPageProxyIOS.mm
Source/WebKit/UIProcess/ios/fullscreen/WKFullScreenWindowControllerIOS.mm
Source/WebKit/WebProcess/WebPage/WebPage.h
Source/WebKit/WebProcess/WebPage/WebPage.messages.in
Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm