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

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

Issue 567783002: Add modifier flags to MotionEvent (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove MotionEvent modifiers Created 6 years, 3 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/motion_event_generic.cc
diff --git a/ui/events/gesture_detection/motion_event_generic.cc b/ui/events/gesture_detection/motion_event_generic.cc
index eff0345024a7d60ebd25cb48a71c98712d75d14a..afda52ad98caf710d5b736e9ab5ee91159980f3f 100644
--- a/ui/events/gesture_detection/motion_event_generic.cc
+++ b/ui/events/gesture_detection/motion_event_generic.cc
@@ -35,7 +35,11 @@ PointerProperties::PointerProperties(float x, float y)
}
MotionEventGeneric::MotionEventGeneric()
- : action_(ACTION_CANCEL), id_(0), action_index_(0), button_state_(0) {
+ : action_(ACTION_CANCEL),
+ id_(0),
+ action_index_(0),
+ button_state_(0),
+ flags_(0) {
}
MotionEventGeneric::MotionEventGeneric(Action action,
@@ -45,7 +49,8 @@ MotionEventGeneric::MotionEventGeneric(Action action,
event_time_(event_time),
id_(0),
action_index_(0),
- button_state_(0) {
+ button_state_(0),
+ flags_(0) {
PushPointer(pointer);
}
@@ -55,6 +60,7 @@ MotionEventGeneric::MotionEventGeneric(const MotionEventGeneric& other)
id_(other.id_),
action_index_(other.action_index_),
button_state_(other.button_state_),
+ flags_(other.flags_),
pointers_(other.pointers_) {
}
@@ -132,6 +138,10 @@ int MotionEventGeneric::GetButtonState() const {
return button_state_;
}
+int MotionEventGeneric::GetFlags() const {
+ return flags_;
+}
+
base::TimeTicks MotionEventGeneric::GetEventTime() const {
return event_time_;
}
« no previous file with comments | « ui/events/gesture_detection/motion_event_generic.h ('k') | ui/events/gesture_detection/motion_event_generic_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698