| OLD | NEW |
| 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 #include "ui/events/ozone/evdev/touch_event_converter_evdev.h" | 5 #include "ui/events/ozone/evdev/touch_event_converter_evdev.h" |
| 6 | 6 |
| 7 #include <errno.h> | 7 #include <errno.h> |
| 8 #include <linux/input.h> | 8 #include <linux/input.h> |
| 9 #include <stddef.h> | 9 #include <stddef.h> |
| 10 #include <unistd.h> | 10 #include <unistd.h> |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 96 void DispatchMouseButtonEvent(const MouseButtonEventParams& params) override { | 96 void DispatchMouseButtonEvent(const MouseButtonEventParams& params) override { |
| 97 } | 97 } |
| 98 void DispatchMouseWheelEvent(const MouseWheelEventParams& params) override {} | 98 void DispatchMouseWheelEvent(const MouseWheelEventParams& params) override {} |
| 99 void DispatchPinchEvent(const PinchEventParams& params) override {} | 99 void DispatchPinchEvent(const PinchEventParams& params) override {} |
| 100 void DispatchScrollEvent(const ScrollEventParams& params) override {} | 100 void DispatchScrollEvent(const ScrollEventParams& params) override {} |
| 101 void DispatchTouchEvent(const TouchEventParams& params) override { | 101 void DispatchTouchEvent(const TouchEventParams& params) override { |
| 102 callback_.Run(params); | 102 callback_.Run(params); |
| 103 } | 103 } |
| 104 | 104 |
| 105 void DispatchKeyboardDevicesUpdated( | 105 void DispatchKeyboardDevicesUpdated( |
| 106 const std::vector<KeyboardDevice>& devices) override {} | 106 const std::vector<InputDevice>& devices) override {} |
| 107 void DispatchTouchscreenDevicesUpdated( | 107 void DispatchTouchscreenDevicesUpdated( |
| 108 const std::vector<TouchscreenDevice>& devices) override {} | 108 const std::vector<TouchscreenDevice>& devices) override {} |
| 109 void DispatchMouseDevicesUpdated( | 109 void DispatchMouseDevicesUpdated( |
| 110 const std::vector<InputDevice>& devices) override {} | 110 const std::vector<InputDevice>& devices) override {} |
| 111 void DispatchTouchpadDevicesUpdated( | 111 void DispatchTouchpadDevicesUpdated( |
| 112 const std::vector<InputDevice>& devices) override {} | 112 const std::vector<InputDevice>& devices) override {} |
| 113 void DispatchDeviceListsComplete() override {} | 113 void DispatchDeviceListsComplete() override {} |
| 114 | 114 |
| 115 private: | 115 private: |
| 116 base::Callback<void(const TouchEventParams& params)> callback_; | 116 base::Callback<void(const TouchEventParams& params)> callback_; |
| (...skipping 925 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1042 event = dispatched_event(3); | 1042 event = dispatched_event(3); |
| 1043 EXPECT_EQ(ui::ET_TOUCH_RELEASED, event.type); | 1043 EXPECT_EQ(ui::ET_TOUCH_RELEASED, event.type); |
| 1044 EXPECT_EQ(8930, event.location.x()); | 1044 EXPECT_EQ(8930, event.location.x()); |
| 1045 EXPECT_EQ(980, event.location.y()); | 1045 EXPECT_EQ(980, event.location.y()); |
| 1046 EXPECT_EQ(EventPointerType::POINTER_TYPE_PEN, | 1046 EXPECT_EQ(EventPointerType::POINTER_TYPE_PEN, |
| 1047 event.pointer_details.pointer_type); | 1047 event.pointer_details.pointer_type); |
| 1048 EXPECT_EQ(0.f / 1024, event.pointer_details.force); | 1048 EXPECT_EQ(0.f / 1024, event.pointer_details.force); |
| 1049 } | 1049 } |
| 1050 | 1050 |
| 1051 } // namespace ui | 1051 } // namespace ui |
| OLD | NEW |