| OLD | NEW |
| 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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/ozone/events_ozone.h" | 5 #include "ui/events/ozone/events_ozone.h" |
| 6 | 6 |
| 7 #include "ui/events/event.h" | 7 #include "ui/events/event.h" |
| 8 | 8 |
| 9 namespace ui { | 9 namespace ui { |
| 10 | 10 |
| (...skipping 12 matching lines...) Expand all Loading... |
| 23 } else if (native_ui_event->IsTouchEvent()) { | 23 } else if (native_ui_event->IsTouchEvent()) { |
| 24 ui::TouchEvent touch_event(native_event); | 24 ui::TouchEvent touch_event(native_event); |
| 25 callback.Run(&touch_event); | 25 callback.Run(&touch_event); |
| 26 } else if (native_ui_event->IsScrollEvent()) { | 26 } else if (native_ui_event->IsScrollEvent()) { |
| 27 ui::ScrollEvent scroll_event(native_event); | 27 ui::ScrollEvent scroll_event(native_event); |
| 28 callback.Run(&scroll_event); | 28 callback.Run(&scroll_event); |
| 29 } else if (native_ui_event->IsGestureEvent()) { | 29 } else if (native_ui_event->IsGestureEvent()) { |
| 30 callback.Run(native_ui_event); | 30 callback.Run(native_ui_event); |
| 31 // TODO(mohsen): Use the same pattern for scroll/touch/wheel events. | 31 // TODO(mohsen): Use the same pattern for scroll/touch/wheel events. |
| 32 // Apparently, there is no need for them to wrap the |native_event|. | 32 // Apparently, there is no need for them to wrap the |native_event|. |
| 33 } else if (native_ui_event->IsGamepadEvent()) { |
| 34 callback.Run(native_ui_event); |
| 33 } else { | 35 } else { |
| 34 NOTREACHED(); | 36 NOTREACHED(); |
| 35 } | 37 } |
| 36 } | 38 } |
| 37 | 39 |
| 38 } // namespace ui | 40 } // namespace ui |
| OLD | NEW |