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

Unified Diff: cc/trees/layer_tree_host_impl.h

Issue 2907053004: GSB uses delta_hints to calculate scrolling chain. (Closed)
Patch Set: review comments addressed. Created 3 years, 6 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 | « cc/input/scroll_state_data.cc ('k') | cc/trees/layer_tree_host_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/layer_tree_host_impl.h
diff --git a/cc/trees/layer_tree_host_impl.h b/cc/trees/layer_tree_host_impl.h
index 611f24b77fc3db578a919622ffb3643d02f6207d..9874a351cebd2d1a0d64c8f64f6a8f6541171361 100644
--- a/cc/trees/layer_tree_host_impl.h
+++ b/cc/trees/layer_tree_host_impl.h
@@ -169,7 +169,7 @@ class CC_EXPORT LayerTreeHostImpl
InputHandler::ScrollStatus RootScrollBegin(
ScrollState* scroll_state,
InputHandler::ScrollInputType type) override;
- ScrollStatus ScrollAnimatedBegin(const gfx::Point& viewport_point) override;
+ ScrollStatus ScrollAnimatedBegin(ScrollState* scroll_state) override;
InputHandler::ScrollStatus ScrollAnimated(
const gfx::Point& viewport_point,
const gfx::Vector2dF& scroll_delta,
@@ -633,6 +633,15 @@ class CC_EXPORT LayerTreeHostImpl
BeginFrameTracker current_begin_frame_tracker_;
private:
+ // Transforms viewport start point and scroll delta to local start point and
+ // local delta, respectively.
bokan 2017/06/23 18:56:44 Please also document what the return value means.
sahel 2017/06/23 20:00:59 Done.
+ bool CalculateLocalScrollDeltaAndStartPoint(
+ const ScrollNode& scroll_node,
+ const gfx::PointF& viewport_point,
+ const gfx::Vector2dF& viewport_delta,
+ const ScrollTree& scroll_tree,
+ gfx::Vector2dF* out_local_scroll_delta,
+ gfx::PointF* out_local_start_point = nullptr);
gfx::Vector2dF ScrollNodeWithViewportSpaceDelta(
ScrollNode* scroll_node,
const gfx::PointF& viewport_point,
@@ -664,6 +673,8 @@ class CC_EXPORT LayerTreeHostImpl
InputHandler::ScrollInputType type);
bool IsInitialScrollHitTestReliable(LayerImpl* layer, const gfx::PointF&);
void DistributeScrollDelta(ScrollState* scroll_state);
+ bool CanConsumeDelta(ScrollNode* scroll_node,
+ const ScrollState& scroll_state);
bool AnimatePageScale(base::TimeTicks monotonic_time);
bool AnimateScrollbars(base::TimeTicks monotonic_time);
« no previous file with comments | « cc/input/scroll_state_data.cc ('k') | cc/trees/layer_tree_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698