| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #include "ui/events/event.h" | 5 #include "ui/events/event.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/memory/ptr_util.h" | 9 #include "base/memory/ptr_util.h" |
| 10 | 10 |
| (...skipping 461 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 472 //////////////////////////////////////////////////////////////////////////////// | 472 //////////////////////////////////////////////////////////////////////////////// |
| 473 // LocatedEvent | 473 // LocatedEvent |
| 474 | 474 |
| 475 LocatedEvent::~LocatedEvent() { | 475 LocatedEvent::~LocatedEvent() { |
| 476 } | 476 } |
| 477 | 477 |
| 478 LocatedEvent::LocatedEvent(const base::NativeEvent& native_event) | 478 LocatedEvent::LocatedEvent(const base::NativeEvent& native_event) |
| 479 : Event(native_event, | 479 : Event(native_event, |
| 480 EventTypeFromNative(native_event), | 480 EventTypeFromNative(native_event), |
| 481 EventFlagsFromNative(native_event)), | 481 EventFlagsFromNative(native_event)), |
| 482 location_(EventLocationFromNative(native_event)), | 482 location_(EventLocationFromNativeF(native_event)), |
| 483 root_location_(location_) { | 483 root_location_(location_) {} |
| 484 } | |
| 485 | 484 |
| 486 LocatedEvent::LocatedEvent(EventType type, | 485 LocatedEvent::LocatedEvent(EventType type, |
| 487 const gfx::PointF& location, | 486 const gfx::PointF& location, |
| 488 const gfx::PointF& root_location, | 487 const gfx::PointF& root_location, |
| 489 base::TimeTicks time_stamp, | 488 base::TimeTicks time_stamp, |
| 490 int flags) | 489 int flags) |
| 491 : Event(type, time_stamp, flags), | 490 : Event(type, time_stamp, flags), |
| 492 location_(location), | 491 location_(location), |
| 493 root_location_(root_location) {} | 492 root_location_(root_location) {} |
| 494 | 493 |
| (...skipping 896 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1391 flags | EF_FROM_TOUCH), | 1390 flags | EF_FROM_TOUCH), |
| 1392 details_(details), | 1391 details_(details), |
| 1393 unique_touch_event_id_(unique_touch_event_id) { | 1392 unique_touch_event_id_(unique_touch_event_id) { |
| 1394 latency()->set_source_event_type(ui::SourceEventType::TOUCH); | 1393 latency()->set_source_event_type(ui::SourceEventType::TOUCH); |
| 1395 } | 1394 } |
| 1396 | 1395 |
| 1397 GestureEvent::~GestureEvent() { | 1396 GestureEvent::~GestureEvent() { |
| 1398 } | 1397 } |
| 1399 | 1398 |
| 1400 } // namespace ui | 1399 } // namespace ui |
| OLD | NEW |