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

Unified Diff: cc/layer_tree_host_impl.cc

Issue 11365238: cc: Return whether any layer was scrolled from InputHandlerClient::scrollBy. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 1 month 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 | « cc/layer_tree_host_impl.h ('k') | webkit/compositor_bindings/web_to_ccinput_handler_adapter.cc » ('j') | 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 01afc00f5ce1147c2ee63b3574c2a64fc0d37e54..514bff97aee23e5f8cc94d6a59100e45ae1ac23f 100644
--- a/cc/layer_tree_host_impl.cc
+++ b/cc/layer_tree_host_impl.cc
@@ -1145,11 +1145,11 @@ static gfx::Vector2dF scrollLayerWithLocalDelta(LayerImpl& layerImpl, gfx::Vecto
return layerImpl.scrollDelta() - previousDelta;
}
-void LayerTreeHostImpl::scrollBy(gfx::Point viewportPoint, gfx::Vector2d scrollDelta)
+bool LayerTreeHostImpl::scrollBy(gfx::Point viewportPoint, gfx::Vector2d scrollDelta)
{
TRACE_EVENT0("cc", "LayerTreeHostImpl::scrollBy");
if (!m_currentlyScrollingLayerImpl)
- return;
+ return false;
gfx::Vector2dF pendingDelta = scrollDelta;
@@ -1190,7 +1190,9 @@ void LayerTreeHostImpl::scrollBy(gfx::Point viewportPoint, gfx::Vector2d scrollD
if (!scrollDelta.IsZero() && gfx::ToFlooredVector2d(pendingDelta).IsZero()) {
m_client->setNeedsCommitOnImplThread();
m_client->setNeedsRedrawOnImplThread();
+ return true;
danakj 2012/11/14 02:44:22 I guess this function eats the whole pendingDelta
}
+ return false;
}
void LayerTreeHostImpl::clearCurrentlyScrollingLayer()
« no previous file with comments | « cc/layer_tree_host_impl.h ('k') | webkit/compositor_bindings/web_to_ccinput_handler_adapter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698