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

Unified Diff: content/browser/android/overscroll_glow.h

Issue 20045007: Use DidOverscrollParams in the browser (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase 2 Created 6 years, 8 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 | « no previous file | content/browser/android/overscroll_glow.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/android/overscroll_glow.h
diff --git a/content/browser/android/overscroll_glow.h b/content/browser/android/overscroll_glow.h
index ed1dba16a5fbc65251f82a46f745a5244e437d99..0a555d41b7af8ac39c87889b4d36099bca796680 100644
--- a/content/browser/android/overscroll_glow.h
+++ b/content/browser/android/overscroll_glow.h
@@ -43,13 +43,13 @@ class OverscrollGlow {
void Disable();
// Effect layers will be attached to |overscrolling_layer| if necessary.
- // |overscroll| is the accumulated overscroll for the current gesture, in
- // device pixels. |velocity| is the instantaneous velocity of the overscroll,
- // in device pixels / second.
+ // |accumulated_overscroll| and |overscroll_delta| are in device pixels, while
+ // |velocity| is in device pixels / second.
// Returns true if the effect still needs animation ticks.
bool OnOverscrolled(cc::Layer* overscrolling_layer,
base::TimeTicks current_time,
- gfx::Vector2dF overscroll,
+ gfx::Vector2dF accumulated_overscroll,
+ gfx::Vector2dF overscroll_delta,
gfx::Vector2dF velocity);
// Returns true if the effect still needs animation ticks.
@@ -77,12 +77,11 @@ class OverscrollGlow {
bool NeedsAnimate() const;
void UpdateLayerAttachment(cc::Layer* parent);
void Detach();
- void Pull(base::TimeTicks current_time,
- gfx::Vector2dF added_overscroll);
+ void Pull(base::TimeTicks current_time, gfx::Vector2dF overscroll_delta);
void Absorb(base::TimeTicks current_time,
gfx::Vector2dF velocity,
- gfx::Vector2dF overscroll,
- gfx::Vector2dF old_overscroll);
+ bool x_overscroll_started,
+ bool y_overscroll_started);
void Release(base::TimeTicks current_time);
void ReleaseAxis(Axis axis, base::TimeTicks current_time);
@@ -91,8 +90,6 @@ class OverscrollGlow {
scoped_ptr<EdgeEffect> edge_effects_[EdgeEffect::EDGE_COUNT];
DisplayParameters display_params_;
- gfx::Vector2dF old_overscroll_;
- gfx::Vector2dF old_velocity_;
bool enabled_;
bool initialized_;
« no previous file with comments | « no previous file | content/browser/android/overscroll_glow.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698