Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1875)

Unified Diff: Source/web/PageScaleConstraintsSet.cpp

Issue 655763002: Revert of Made top controls work with virtual viewport pinch-to-zoom. (Blink) (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/core/frame/PinchViewport.cpp ('k') | Source/web/WebViewImpl.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/web/PageScaleConstraintsSet.cpp
diff --git a/Source/web/PageScaleConstraintsSet.cpp b/Source/web/PageScaleConstraintsSet.cpp
index d8963d243aeb0ca5a44ee735ee4a0ef8007136bf..7bdfa3a26556b81745e0e354dc4ad913ea58b22b 100644
--- a/Source/web/PageScaleConstraintsSet.cpp
+++ b/Source/web/PageScaleConstraintsSet.cpp
@@ -149,15 +149,14 @@
if (m_pageDefinedConstraints.minimumScale < finalConstraints().minimumScale
&& m_userAgentConstraints.minimumScale < finalConstraints().minimumScale
&& contentsSize.width()
- && m_viewSize.width()) {
- return expandedIntSize(FloatSize(contentsSize.width(), computeHeightByAspectRatio(contentsSize.width(), m_viewSize)));
- }
+ && m_viewSize.width())
+ return IntSize(contentsSize.width(), computeHeightByAspectRatio(contentsSize.width(), m_viewSize));
// If there is a minimum scale (or there's no content size yet), the frame size should match the viewport
// size at minimum scale, since the viewport must always be contained by the frame.
- FloatSize frameSize(m_viewSize);
+ IntSize frameSize(m_viewSize);
frameSize.scale(1 / finalConstraints().minimumScale);
- return expandedIntSize(frameSize);
+ return frameSize;
}
void PageScaleConstraintsSet::adjustForAndroidWebViewQuirks(const ViewportDescription& description, int layoutFallbackWidth, float deviceScaleFactor, bool supportTargetDensityDPI, bool wideViewportQuirkEnabled, bool useWideViewport, bool loadWithOverviewMode, bool nonUserScalableQuirkEnabled)
« no previous file with comments | « Source/core/frame/PinchViewport.cpp ('k') | Source/web/WebViewImpl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698