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

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

Issue 617423002: Make GestureTextSelector detect its own gestures (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Sort gyp/gn Created 6 years, 2 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.cc
diff --git a/ui/events/gesture_detection/gesture_provider.cc b/ui/events/gesture_detection/gesture_provider.cc
index 981eb0affd10cab712dceea21624a0f32d893d57..51d119bed81163ef1794805ced8b3c2e051416ec 100644
--- a/ui/events/gesture_detection/gesture_provider.cc
+++ b/ui/events/gesture_detection/gesture_provider.cc
@@ -10,7 +10,9 @@
#include "base/debug/trace_event.h"
#include "ui/events/event_constants.h"
#include "ui/events/gesture_detection/gesture_event_data.h"
+#include "ui/events/gesture_detection/gesture_listeners.h"
#include "ui/events/gesture_detection/motion_event.h"
+#include "ui/events/gesture_detection/scale_gesture_listeners.h"
#include "ui/gfx/geometry/point_f.h"
namespace ui {
@@ -72,10 +74,9 @@ GestureProvider::Config::~Config() {
// GestureProvider::GestureListener
-class GestureProvider::GestureListenerImpl
- : public ScaleGestureDetector::ScaleGestureListener,
- public GestureDetector::GestureListener,
- public GestureDetector::DoubleTapListener {
+class GestureProvider::GestureListenerImpl : public ScaleGestureListener,
+ public GestureListener,
+ public DoubleTapListener {
public:
GestureListenerImpl(const GestureProvider::Config& config,
GestureProviderClient* client)
@@ -192,7 +193,7 @@ class GestureProvider::GestureListenerImpl
GestureTouchUMAHistogram::RecordGestureEvent(gesture);
}
- // ScaleGestureDetector::ScaleGestureListener implementation.
+ // ScaleGestureListener implementation.
virtual bool OnScaleBegin(const ScaleGestureDetector& detector,
const MotionEvent& e) OVERRIDE {
if (ignore_multitouch_zoom_events_ && !detector.InDoubleTapMode())
@@ -262,7 +263,7 @@ class GestureProvider::GestureListenerImpl
return true;
}
- // GestureDetector::GestureListener implementation.
+ // GestureListener implementation.
virtual bool OnDown(const MotionEvent& e) OVERRIDE {
GestureEventDetails tap_details(ET_GESTURE_TAP_DOWN);
Send(CreateGesture(tap_details, e));
@@ -442,7 +443,7 @@ class GestureProvider::GestureListenerImpl
return false;
}
- // GestureDetector::DoubleTapListener implementation.
+ // DoubleTapListener implementation.
virtual bool OnSingleTapConfirmed(const MotionEvent& e) OVERRIDE {
// Long taps in the edges of the screen have their events delayed by
// ContentViewHolder for tab swipe operations. As a consequence of the delay
« no previous file with comments | « ui/events/gesture_detection/gesture_listeners.cc ('k') | ui/events/gesture_detection/scale_gesture_detector.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698