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

Unified Diff: ui/events/event.cc

Issue 2720133002: Make pinch zoom work on chromeos by setting touch id correctly (Closed)
Patch Set: pinch zoom Created 3 years, 10 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 | « ui/events/event.h ('k') | ui/events/event_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/events/event.cc
diff --git a/ui/events/event.cc b/ui/events/event.cc
index f3659017ddd5736d050a229311e3adf0cf0940c6..8ebf5fc25b0dbfb6ed43ff0e09ec38e38f1b7322 100644
--- a/ui/events/event.cc
+++ b/ui/events/event.cc
@@ -762,6 +762,15 @@ void MouseEvent::SetClickCount(int click_count) {
set_flags(f);
}
+void MouseEvent::set_pointer_details(const PointerDetails& details) {
+ DCHECK_NE(EventPointerType::POINTER_TYPE_TOUCH,
+ pointer_details_.pointer_type);
+ DCHECK_NE(EventPointerType::POINTER_TYPE_TOUCH, details.pointer_type);
+ DCHECK(pointer_details_.id == PointerEvent::kMousePointerId ||
+ details.id != PointerEvent::kMousePointerId);
+ pointer_details_ = details;
+}
+
////////////////////////////////////////////////////////////////////////////////
// MouseWheelEvent
@@ -972,6 +981,11 @@ void TouchEvent::FixRotationAngle() {
rotation_angle_ -= 180;
}
+void TouchEvent::set_pointer_details(const PointerDetails& pointer_details) {
+ DCHECK_EQ(pointer_details_.id, pointer_details.id);
+ pointer_details_ = pointer_details;
+}
+
////////////////////////////////////////////////////////////////////////////////
// PointerEvent
« no previous file with comments | « ui/events/event.h ('k') | ui/events/event_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698