| Index: ui/events/event.cc
|
| diff --git a/ui/events/event.cc b/ui/events/event.cc
|
| index e93a0aedf618c3810be06c34b6b253f258c29be3..20f336caf7b18c934d6fc0ecc7f71cab4f6e706a 100644
|
| --- a/ui/events/event.cc
|
| +++ b/ui/events/event.cc
|
| @@ -108,6 +108,11 @@ bool X11EventHasNonStandardState(const base::NativeEvent& event) {
|
| #endif
|
| }
|
|
|
| +unsigned long long get_next_touch_event_id() {
|
| + static unsigned long long id = 0;
|
| + return id++;
|
| +}
|
| +
|
| } // namespace
|
|
|
| namespace ui {
|
| @@ -170,6 +175,10 @@ bool Event::HasNativeEvent() const {
|
| return !!std::memcmp(&native_event_, &null_event, sizeof(null_event));
|
| }
|
|
|
| +void Event::DisableSynchronousHandling() {
|
| + result_ = static_cast<EventResult>(result_ | ER_DISABLE_SYNC_HANDLING);
|
| +}
|
| +
|
| void Event::StopPropagation() {
|
| // TODO(sad): Re-enable these checks once View uses dispatcher to dispatch
|
| // events.
|
| @@ -514,6 +523,7 @@ void MouseWheelEvent::UpdateForRootTransform(
|
| TouchEvent::TouchEvent(const base::NativeEvent& native_event)
|
| : LocatedEvent(native_event),
|
| touch_id_(GetTouchId(native_event)),
|
| + unique_event_id_(get_next_touch_event_id()),
|
| radius_x_(GetTouchRadiusX(native_event)),
|
| radius_y_(GetTouchRadiusY(native_event)),
|
| rotation_angle_(GetTouchAngle(native_event)),
|
| @@ -537,6 +547,7 @@ TouchEvent::TouchEvent(EventType type,
|
| base::TimeDelta time_stamp)
|
| : LocatedEvent(type, location, location, time_stamp, 0),
|
| touch_id_(touch_id),
|
| + unique_event_id_(get_next_touch_event_id()),
|
| radius_x_(0.0f),
|
| radius_y_(0.0f),
|
| rotation_angle_(0.0f),
|
| @@ -555,6 +566,7 @@ TouchEvent::TouchEvent(EventType type,
|
| float force)
|
| : LocatedEvent(type, location, location, time_stamp, flags),
|
| touch_id_(touch_id),
|
| + unique_event_id_(get_next_touch_event_id()),
|
| radius_x_(radius_x),
|
| radius_y_(radius_y),
|
| rotation_angle_(angle),
|
|
|