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

Unified Diff: cc/layer_tree_host_impl.cc

Issue 11447024: Disable pinch zoom viewport for non-compositor scaling (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: use NULL instead of 0 Created 8 years 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: cc/layer_tree_host_impl.cc
diff --git a/cc/layer_tree_host_impl.cc b/cc/layer_tree_host_impl.cc
index 8f32526fbc635f0ef6ac3375c45755e1b89b4618..0694984a22bbd4675a47d4bdeea118387578040f 100644
--- a/cc/layer_tree_host_impl.cc
+++ b/cc/layer_tree_host_impl.cc
@@ -1298,7 +1298,9 @@ bool LayerTreeHostImpl::scrollBy(const gfx::Point& viewportPoint,
if (!layerImpl->scrollable())
continue;
- PinchZoomViewport* viewport = layerImpl == m_rootScrollLayerImpl ? &m_pinchZoomViewport : 0;
+ PinchZoomViewport* viewport = NULL;
+ if (m_settings.pageScalePinchZoomEnabled && layerImpl == m_rootScrollLayerImpl)
+ viewport = &m_pinchZoomViewport;
gfx::Vector2dF appliedDelta;
if (m_scrollDeltaIsInViewportSpace) {
float scaleFromViewportToScreenSpace = m_deviceScaleFactor;
« 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