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 #ifndef UI_EVENTS_OZONE_EVDEV_EVENT_MODIFIERS_EVDEV_H_ | 5 #ifndef UI_EVENTS_OZONE_EVDEV_EVENT_MODIFIERS_EVDEV_H_ |
6 #define UI_EVENTS_OZONE_EVDEV_EVENT_MODIFIERS_EVDEV_H_ | 6 #define UI_EVENTS_OZONE_EVDEV_EVENT_MODIFIERS_EVDEV_H_ |
7 | 7 |
8 #include "base/macros.h" | 8 #include "base/macros.h" |
9 #include "ui/events/ozone/evdev/events_ozone_evdev_export.h" | 9 #include "ui/events/ozone/evdev/events_ozone_evdev_export.h" |
10 | 10 |
11 namespace ui { | 11 namespace ui { |
12 | 12 |
13 enum { | 13 enum { |
14 EVDEV_MODIFIER_NONE, | 14 EVDEV_MODIFIER_NONE, |
15 EVDEV_MODIFIER_CAPS_LOCK, | |
16 EVDEV_MODIFIER_SHIFT, | 15 EVDEV_MODIFIER_SHIFT, |
17 EVDEV_MODIFIER_CONTROL, | 16 EVDEV_MODIFIER_CONTROL, |
18 EVDEV_MODIFIER_ALT, | 17 EVDEV_MODIFIER_ALT, |
| 18 EVDEV_MODIFIER_COMMAND, |
| 19 EVDEV_MODIFIER_ALTGR, |
| 20 EVDEV_MODIFIER_MOD3, |
| 21 EVDEV_MODIFIER_CAPS_LOCK, |
19 EVDEV_MODIFIER_LEFT_MOUSE_BUTTON, | 22 EVDEV_MODIFIER_LEFT_MOUSE_BUTTON, |
20 EVDEV_MODIFIER_MIDDLE_MOUSE_BUTTON, | 23 EVDEV_MODIFIER_MIDDLE_MOUSE_BUTTON, |
21 EVDEV_MODIFIER_RIGHT_MOUSE_BUTTON, | 24 EVDEV_MODIFIER_RIGHT_MOUSE_BUTTON, |
22 EVDEV_MODIFIER_BACK_MOUSE_BUTTON, | 25 EVDEV_MODIFIER_BACK_MOUSE_BUTTON, |
23 EVDEV_MODIFIER_FORWARD_MOUSE_BUTTON, | 26 EVDEV_MODIFIER_FORWARD_MOUSE_BUTTON, |
24 EVDEV_MODIFIER_COMMAND, | |
25 EVDEV_MODIFIER_ALTGR, | |
26 EVDEV_MODIFIER_MOD3, | |
27 EVDEV_NUM_MODIFIERS | 27 EVDEV_NUM_MODIFIERS |
28 }; | 28 }; |
29 | 29 |
30 // Modifier key state for Evdev. | 30 // Modifier key state for Evdev. |
31 // | 31 // |
32 // Chrome relies on the underlying OS to interpret modifier keys such as Shift, | 32 // Chrome relies on the underlying OS to interpret modifier keys such as Shift, |
33 // Ctrl, and Alt. The Linux input subsystem does not assign any special meaning | 33 // Ctrl, and Alt. The Linux input subsystem does not assign any special meaning |
34 // to these keys, so this work must happen at a higher layer (normally X11 or | 34 // to these keys, so this work must happen at a higher layer (normally X11 or |
35 // the console driver). When using evdev directly, we must do it ourselves. | 35 // the console driver). When using evdev directly, we must do it ourselves. |
36 // | 36 // |
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
77 | 77 |
78 // Update modifier_flags_ from modifiers_down_ and modifier_flags_locked_. | 78 // Update modifier_flags_ from modifiers_down_ and modifier_flags_locked_. |
79 void UpdateFlags(unsigned int modifier); | 79 void UpdateFlags(unsigned int modifier); |
80 | 80 |
81 DISALLOW_COPY_AND_ASSIGN(EventModifiersEvdev); | 81 DISALLOW_COPY_AND_ASSIGN(EventModifiersEvdev); |
82 }; | 82 }; |
83 | 83 |
84 } // namspace ui | 84 } // namspace ui |
85 | 85 |
86 #endif // UI_EVENTS_OZONE_EVDEV_EVENT_MODIFIERS_EVDEV_H_ | 86 #endif // UI_EVENTS_OZONE_EVDEV_EVENT_MODIFIERS_EVDEV_H_ |
OLD | NEW |