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

Unified Diff: Source/web/WebViewImpl.cpp

Issue 663993003: Don't calculate a top controls adjustment if pinch viewport size is uninitialized. (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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/web/WebViewImpl.cpp
diff --git a/Source/web/WebViewImpl.cpp b/Source/web/WebViewImpl.cpp
index bb5da5197c3c6a016ec05a928e8a3939831f8384..22a3c370d51a7c3675ac7e423d290527402fdaf1 100644
--- a/Source/web/WebViewImpl.cpp
+++ b/Source/web/WebViewImpl.cpp
@@ -1729,6 +1729,10 @@ void WebViewImpl::didUpdateTopControls()
view->setTopControlsViewportAdjustment(topControlsViewportAdjustment);
} else {
PinchViewport& pinchViewport = page()->frameHost().pinchViewport();
+
+ if (!pinchViewport.visibleRect().width() || !pinchViewport.visibleRect().height())
Peter Kasting 2014/10/22 19:32:21 Can this just be "if (pinchViewport.visibleRect().
bokan 2014/10/22 20:08:53 Done.
+ return;
+
pinchViewport.setTopControlsAdjustment(topControlsViewportAdjustment);
// Shrink the FrameView by the amount that will maintain the aspect-ratio with the PinchViewport.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698