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

Unified Diff: cc/layer_tree_host.cc

Issue 11550035: Implement pinch-zoom scaling for main-frame scrollbars and pinch-zoom overlay scrollbars. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Refactor for cleaner state/scrollbar split. Created 7 years, 11 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
Index: cc/layer_tree_host.cc
diff --git a/cc/layer_tree_host.cc b/cc/layer_tree_host.cc
index 862cccd5f084b45ee9bd25b4bb9da964a53a68ce..fadee527be9dbfaf746f23f779b5e39e5472e7ba 100644
--- a/cc/layer_tree_host.cc
+++ b/cc/layer_tree_host.cc
@@ -276,7 +276,7 @@ static void pushPropertiesRecursive(Layer* layer, LayerImpl* layerImpl)
const std::vector<scoped_refptr<Layer> >& children = layer->children();
const ScopedPtrVector<LayerImpl>& implChildren = layerImpl->children();
- DCHECK_EQ(children.size(), implChildren.size());
+ DCHECK(children.size() <= implChildren.size());
Ian Vollick 2013/01/15 20:33:48 I think we need to be more explicit about impl-onl
for (size_t i = 0; i < children.size(); ++i) {
pushPropertiesRecursive(children[i].get(), implChildren[i]);
@@ -330,6 +330,9 @@ void LayerTreeHost::finishCommitOnImplThread(LayerTreeHostImpl* hostImpl)
syncTree->set_background_color(m_backgroundColor);
syncTree->set_has_transparent_background(m_hasTransparentBackground);
+ if (m_settings.pageScalePinchZoomEnabled)
+ hostImpl->pinchZoomViewport().AddPinchZoomScrollbarsToTree(syncTree);
Ian Vollick 2013/01/15 20:33:48 I don't like that this function is getting littere
+
hostImpl->setViewportSize(layoutViewportSize(), deviceViewportSize());
hostImpl->setDeviceScaleFactor(deviceScaleFactor());
hostImpl->setPageScaleFactorAndLimits(m_pageScaleFactor, m_minPageScaleFactor, m_maxPageScaleFactor);

Powered by Google App Engine
This is Rietveld 408576698