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

Side by Side Diff: ui/events/gesture_detection/gesture_event_data_packet.h

Issue 1989623002: Suppressed MEs for gestures from cancelled PEs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebased Created 4 years, 6 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef UI_EVENTS_GESTURE_DETECTION_GESTURE_EVENT_DATA_PACKET_H_ 5 #ifndef UI_EVENTS_GESTURE_DETECTION_GESTURE_EVENT_DATA_PACKET_H_
6 #define UI_EVENTS_GESTURE_DETECTION_GESTURE_EVENT_DATA_PACKET_H_ 6 #define UI_EVENTS_GESTURE_DETECTION_GESTURE_EVENT_DATA_PACKET_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <stdint.h> 9 #include <stdint.h>
10 10
(...skipping 30 matching lines...) Expand all
41 GestureEventDataPacket(); 41 GestureEventDataPacket();
42 GestureEventDataPacket(const GestureEventDataPacket& other); 42 GestureEventDataPacket(const GestureEventDataPacket& other);
43 ~GestureEventDataPacket(); 43 ~GestureEventDataPacket();
44 GestureEventDataPacket& operator=(const GestureEventDataPacket& other); 44 GestureEventDataPacket& operator=(const GestureEventDataPacket& other);
45 45
46 // Factory methods for creating a packet from a particular event. 46 // Factory methods for creating a packet from a particular event.
47 static GestureEventDataPacket FromTouch(const ui::MotionEvent& touch); 47 static GestureEventDataPacket FromTouch(const ui::MotionEvent& touch);
48 static GestureEventDataPacket FromTouchTimeout( 48 static GestureEventDataPacket FromTouchTimeout(
49 const GestureEventData& gesture); 49 const GestureEventData& gesture);
50 50
51 // Pushes into the GestureEventDataPacket a copy of |gesture| that has the
52 // same unique_touch_event_id as the data packet.
51 void Push(const GestureEventData& gesture); 53 void Push(const GestureEventData& gesture);
52 54
53 const base::TimeTicks& timestamp() const { return timestamp_; } 55 const base::TimeTicks& timestamp() const { return timestamp_; }
54 const GestureEventData& gesture(size_t i) const { return gestures_[i]; } 56 const GestureEventData& gesture(size_t i) const { return gestures_[i]; }
55 size_t gesture_count() const { return gestures_->size(); } 57 size_t gesture_count() const { return gestures_->size(); }
56 GestureSource gesture_source() const { return gesture_source_; } 58 GestureSource gesture_source() const { return gesture_source_; }
57 const gfx::PointF& touch_location() const { return touch_location_; } 59 const gfx::PointF& touch_location() const { return touch_location_; }
58 const gfx::PointF& raw_touch_location() const { return raw_touch_location_; } 60 const gfx::PointF& raw_touch_location() const { return raw_touch_location_; }
59 61
60 // We store the ack with the packet until the packet reaches the 62 // We store the ack with the packet until the packet reaches the
(...skipping 15 matching lines...) Expand all
76 gfx::PointF touch_location_; 78 gfx::PointF touch_location_;
77 gfx::PointF raw_touch_location_; 79 gfx::PointF raw_touch_location_;
78 GestureSource gesture_source_; 80 GestureSource gesture_source_;
79 AckState ack_state_; 81 AckState ack_state_;
80 uint32_t unique_touch_event_id_; 82 uint32_t unique_touch_event_id_;
81 }; 83 };
82 84
83 } // namespace ui 85 } // namespace ui
84 86
85 #endif // UI_EVENTS_GESTURE_DETECTION_GESTURE_EVENT_DATA_PACKET_H_ 87 #endif // UI_EVENTS_GESTURE_DETECTION_GESTURE_EVENT_DATA_PACKET_H_
OLDNEW
« no previous file with comments | « ui/events/gesture_detection/gesture_event_data.cc ('k') | ui/events/gesture_detection/gesture_event_data_packet.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698