| Index: content/browser/android/overscroll_glow.h
|
| diff --git a/content/browser/android/overscroll_glow.h b/content/browser/android/overscroll_glow.h
|
| index 31497cd6ffed4322e2d5051b51986dd277294fc2..93858991f4b11b47c65ee65b9d2d6528790229eb 100644
|
| --- a/content/browser/android/overscroll_glow.h
|
| +++ b/content/browser/android/overscroll_glow.h
|
| @@ -33,28 +33,36 @@ class OverscrollGlow {
|
|
|
| ~OverscrollGlow();
|
|
|
| + // If false, the glow will be deactivated, and subsequent calls to
|
| + // OnOverscrolled or Animate will have no effect. Defaults to enabled.
|
| + void SetEnabled(bool enabled);
|
| +
|
| + // |overscroll| is the accumulated overscroll for the current gesture.
|
| + // |velocity| is the instantaneous velocity for the overscroll.
|
| void OnOverscrolled(base::TimeTicks current_time,
|
| gfx::Vector2dF overscroll,
|
| gfx::Vector2dF velocity);
|
| +
|
| // Returns true if the effect still needs animation ticks.
|
| bool Animate(base::TimeTicks current_time);
|
| - void Finish();
|
|
|
| // Returns true if the effect needs animation ticks.
|
| - bool IsActive() const;
|
| + bool NeedsAnimate() const;
|
|
|
| // The root layer of the effect (not necessarily of the tree).
|
| scoped_refptr<cc::Layer> root_layer() const {
|
| return root_layer_;
|
| }
|
|
|
| + // Horizontal overscroll will be ignored when false.
|
| void set_horizontal_overscroll_enabled(bool enabled) {
|
| horizontal_overscroll_enabled_ = enabled;
|
| }
|
| + // Vertical overscroll will be ignored when false.
|
| void set_vertical_overscroll_enabled(bool enabled) {
|
| vertical_overscroll_enabled_ = enabled;
|
| }
|
| -
|
| + // The size of the layer for which edges will be animated.
|
| void set_size(gfx::SizeF size) {
|
| size_ = size;
|
| }
|
| @@ -78,6 +86,7 @@ class OverscrollGlow {
|
|
|
| scoped_ptr<EdgeEffect> edge_effects_[EdgeEffect::EDGE_COUNT];
|
|
|
| + bool enabled_;
|
| gfx::SizeF size_;
|
| gfx::Vector2dF old_overscroll_;
|
| gfx::Vector2dF old_velocity_;
|
|
|