| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 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 #ifndef UI_EVENTS_OZONE_EVDEV_EVENT_DEVICE_INFO_H_ | 5 #ifndef UI_EVENTS_OZONE_EVDEV_EVENT_DEVICE_INFO_H_ |
| 6 #define UI_EVENTS_OZONE_EVDEV_EVENT_DEVICE_INFO_H_ | 6 #define UI_EVENTS_OZONE_EVDEV_EVENT_DEVICE_INFO_H_ |
| 7 | 7 |
| 8 #include <limits.h> | 8 #include <limits.h> |
| 9 #include <linux/input.h> | 9 #include <linux/input.h> |
| 10 #include <stddef.h> | 10 #include <stddef.h> |
| (...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 132 | 132 |
| 133 // Determine whether there's a touchpad on this device. | 133 // Determine whether there's a touchpad on this device. |
| 134 bool HasTouchpad() const; | 134 bool HasTouchpad() const; |
| 135 | 135 |
| 136 // Determine whether there's a tablet on this device. | 136 // Determine whether there's a tablet on this device. |
| 137 bool HasTablet() const; | 137 bool HasTablet() const; |
| 138 | 138 |
| 139 // Determine whether there's a touchscreen on this device. | 139 // Determine whether there's a touchscreen on this device. |
| 140 bool HasTouchscreen() const; | 140 bool HasTouchscreen() const; |
| 141 | 141 |
| 142 // Determine whether there's a gamepad on this deivice. |
| 143 bool HasGamepad() const; |
| 144 |
| 142 // The device type (internal or external.) | 145 // The device type (internal or external.) |
| 143 InputDeviceType device_type() const { return device_type_; } | 146 InputDeviceType device_type() const { return device_type_; } |
| 144 | 147 |
| 145 private: | 148 private: |
| 146 enum class LegacyAbsoluteDeviceType { | 149 enum class LegacyAbsoluteDeviceType { |
| 147 LADT_TOUCHPAD, | 150 LADT_TOUCHPAD, |
| 148 LADT_TOUCHSCREEN, | 151 LADT_TOUCHSCREEN, |
| 149 LADT_TABLET, | 152 LADT_TABLET, |
| 150 LADT_NONE, | 153 LADT_NONE, |
| 151 }; | 154 }; |
| (...skipping 23 matching lines...) Expand all Loading... |
| 175 | 178 |
| 176 // Whether this is an internal or external device. | 179 // Whether this is an internal or external device. |
| 177 InputDeviceType device_type_ = InputDeviceType::INPUT_DEVICE_UNKNOWN; | 180 InputDeviceType device_type_ = InputDeviceType::INPUT_DEVICE_UNKNOWN; |
| 178 | 181 |
| 179 DISALLOW_COPY_AND_ASSIGN(EventDeviceInfo); | 182 DISALLOW_COPY_AND_ASSIGN(EventDeviceInfo); |
| 180 }; | 183 }; |
| 181 | 184 |
| 182 } // namspace ui | 185 } // namspace ui |
| 183 | 186 |
| 184 #endif // UI_EVENTS_OZONE_EVDEV_EVENT_DEVICE_INFO_H_ | 187 #endif // UI_EVENTS_OZONE_EVDEV_EVENT_DEVICE_INFO_H_ |
| OLD | NEW |