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

Unified Diff: ui/events/gesture_detection/gesture_provider.h

Issue 223673006: Support GestureBegin and GestureEnd in ui::GestureProvider (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address jdduke's comments. Created 6 years, 9 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
Index: ui/events/gesture_detection/gesture_provider.h
diff --git a/ui/events/gesture_detection/gesture_provider.h b/ui/events/gesture_detection/gesture_provider.h
index d8542194ccecf19864e1a337354629a2826a9816..f319791b83c2a5d87a062dae4badddfbd60908ad 100644
--- a/ui/events/gesture_detection/gesture_provider.h
+++ b/ui/events/gesture_detection/gesture_provider.h
@@ -33,6 +33,7 @@ class GESTURE_DETECTION_EXPORT GestureProvider {
ScaleGestureDetector::Config scale_gesture_detector_config;
SnapScrollController::Config snap_scroll_controller_config;
bool disable_click_delay;
+ bool gesture_begin_end_types_enabled;
jdduke (slow) 2014/04/03 22:03:28 Maybe a short comment explaining what this does?
tdresser 2014/04/04 16:39:31 Done. Please double check, particularly the commen
};
GestureProvider(const Config& config, GestureProviderClient* client);
@@ -59,6 +60,9 @@ class GESTURE_DETECTION_EXPORT GestureProvider {
// detection allows for rapid and responsive single-tap gestures.
void SetDoubleTapSupportForPageEnabled(bool enabled);
+ // Update whether GestureBegin and GestureEnd events are supported.
+ void SetBeginEndTypesEnabled(bool enabled);
+
// Whether a scroll gesture is in-progress.
bool IsScrollInProgress() const;
@@ -93,6 +97,10 @@ class GESTURE_DETECTION_EXPORT GestureProvider {
bool SendLongTapIfNecessary(const MotionEvent& event);
void EndTouchScrollIfNecessary(base::TimeTicks time,
bool send_scroll_end_event);
+ void OnTouchEventHandlingBegin(const MotionEvent& event);
+ void OnTouchEventHandlingEnd(const MotionEvent& event,
+ bool handled,
+ bool was_touch_scrolling);
GestureProviderClient* const client_;
@@ -124,6 +132,8 @@ class GESTURE_DETECTION_EXPORT GestureProvider {
// opened after a GESTURE_LONG_PRESS, this is used to insert a
// GESTURE_TAP_CANCEL for removing any ::active styling.
base::TimeTicks current_longpress_time_;
+
+ bool gesture_begin_end_types_enabled_;
};
} // namespace ui

Powered by Google App Engine
This is Rietveld 408576698