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

Unified Diff: content/renderer/input/input_handler_proxy.h

Issue 473053002: Properly resume scrolling if a fling ends during a suppressed scroll (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Cleanup Created 6 years, 4 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/renderer/input/input_handler_proxy.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/input/input_handler_proxy.h
diff --git a/content/renderer/input/input_handler_proxy.h b/content/renderer/input/input_handler_proxy.h
index c1b666b62845fc74be8449307458c2f03d37e2b2..8acc09cda627b33a8b3e61995d9271f1e77ef595 100644
--- a/content/renderer/input/input_handler_proxy.h
+++ b/content/renderer/input/input_handler_proxy.h
@@ -66,16 +66,19 @@ class CONTENT_EXPORT InputHandlerProxy
// Schedule a time in the future after which a boost-enabled fling will
// terminate without further momentum from the user (see |Animate()|).
- void FlingBoostExtend(const blink::WebGestureEvent& event);
-
- // Cancel the current fling and insert a GestureScrollBegin if necessary.
- void FlingBoostCancelAndResumeScrollingIfNecessary();
+ void ExtendBoostedFlingTimeout(const blink::WebGestureEvent& event);
// Returns true if we scrolled by the increment.
bool TouchpadFlingScroll(const blink::WebFloatSize& increment);
+ // Returns true if we actually had an active fling to cancel, also notifying
+ // the client that the fling has ended. Note that if a boosted fling is active
+ // and suppressing an active scroll sequence, a synthetic GestureScrollBegin
+ // will be injected to resume scrolling.
+ bool CancelCurrentFling();
+
// Returns true if we actually had an active fling to cancel.
- bool CancelCurrentFling(bool send_fling_stopped_notification);
+ bool CancelCurrentFlingWithoutNotifyingClient();
scoped_ptr<blink::WebGestureCurve> fling_curve_;
// Parameters for the active fling animation, stored in case we need to
@@ -91,7 +94,7 @@ class CONTENT_EXPORT InputHandlerProxy
// The last event that extended the lifetime of the boosted fling. If the
// event was a scroll gesture, a GestureScrollBegin will be inserted if the
- // fling terminates (via |FlingBoostCancelAndResumeScrollingIfNecessary()|).
+ // fling terminates (via |CancelCurrentFling()|).
blink::WebGestureEvent last_fling_boost_event_;
#ifndef NDEBUG
« no previous file with comments | « no previous file | content/renderer/input/input_handler_proxy.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698