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

Unified Diff: cc/layer_tree_host_impl.cc

Issue 12407002: Align physical pixels of scrolled layers (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 10 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
« cc/layer_tree_host_common.cc ('K') | « cc/layer_tree_host_common_unittest.cc ('k') | 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 f9c464d1712c59ee8b4e8583a108952f6403747b..aa32c38e48e0a5c636f59d0d606f3ae3a50c4160 100644
--- a/cc/layer_tree_host_impl.cc
+++ b/cc/layer_tree_host_impl.cc
@@ -919,23 +919,6 @@ LayerImpl* LayerTreeHostImpl::currentlyScrollingLayer() const
return m_activeTree->CurrentlyScrollingLayer();
}
-// Content layers can be either directly scrollable or contained in an outer
-// scrolling layer which applies the scroll transform. Given a content layer,
-// this function returns the associated scroll layer if any.
-static LayerImpl* findScrollLayerForContentLayer(LayerImpl* layerImpl)
-{
- if (!layerImpl)
- return 0;
-
- if (layerImpl->scrollable())
- return layerImpl;
-
- if (layerImpl->drawsContent() && layerImpl->parent() && layerImpl->parent()->scrollable())
- return layerImpl->parent();
-
- return 0;
-}
-
void LayerTreeHostImpl::createPendingTree()
{
CHECK(!m_pendingTree);
@@ -1200,7 +1183,7 @@ InputHandlerClient::ScrollStatus LayerTreeHostImpl::scrollBegin(gfx::Point viewp
return ScrollOnMainThread;
}
- LayerImpl* scrollLayerImpl = findScrollLayerForContentLayer(layerImpl);
+ LayerImpl* scrollLayerImpl = LayerTreeHostCommon::findScrollLayerForContentLayer(layerImpl);
if (!scrollLayerImpl)
continue;
« cc/layer_tree_host_common.cc ('K') | « cc/layer_tree_host_common_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698