| Index: third_party/WebKit/Source/web/WebViewImpl.cpp
|
| diff --git a/third_party/WebKit/Source/web/WebViewImpl.cpp b/third_party/WebKit/Source/web/WebViewImpl.cpp
|
| index fe889d4f9fb92f8fe078d49f546d9d80a5e741bc..03565fbc9376cf84ac5866cd77b12852fabb7dff 100644
|
| --- a/third_party/WebKit/Source/web/WebViewImpl.cpp
|
| +++ b/third_party/WebKit/Source/web/WebViewImpl.cpp
|
| @@ -412,6 +412,7 @@ WebViewImpl::WebViewImpl(WebViewClient* client)
|
| , m_zoomLevel(0)
|
| , m_minimumZoomLevel(zoomFactorToZoomLevel(minTextSizeMultiplier))
|
| , m_maximumZoomLevel(zoomFactorToZoomLevel(maxTextSizeMultiplier))
|
| + , m_zoomFactorForDeviceScaleFactor(1.f)
|
| , m_maximumLegibleScale(1)
|
| , m_doubleTapZoomPageScaleFactor(0)
|
| , m_doubleTapZoomPending(false)
|
| @@ -2958,6 +2959,7 @@ double WebViewImpl::setZoomLevel(double zoomLevel)
|
| LocalFrame* frame = mainFrameImpl()->frame();
|
| if (!WebLocalFrameImpl::pluginContainerFromFrame(frame)) {
|
| float zoomFactor = m_zoomFactorOverride ? m_zoomFactorOverride : static_cast<float>(zoomLevelToZoomFactor(m_zoomLevel));
|
| + zoomFactor *= m_zoomFactorForDeviceScaleFactor;
|
| frame->setPageZoomFactor(zoomFactor);
|
| }
|
|
|
| @@ -3103,6 +3105,14 @@ void WebViewImpl::setDeviceScaleFactor(float scaleFactor)
|
| updateLayerTreeDeviceScaleFactor();
|
| }
|
|
|
| +void WebViewImpl::setZoomFactorForDeviceScaleFactor(float zoomFactorForDeviceScaleFactor)
|
| +{
|
| + m_zoomFactorForDeviceScaleFactor = zoomFactorForDeviceScaleFactor;
|
| + if (!m_layerTreeView)
|
| + return;
|
| + setZoomLevel(m_zoomLevel);
|
| +}
|
| +
|
| void WebViewImpl::setDeviceColorProfile(const WebVector<char>& colorProfile)
|
| {
|
| if (!page())
|
|
|