summaryrefslogtreecommitdiff
path: root/tmk_core/protocol
diff options
context:
space:
mode:
authorRyan <fauxpark@gmail.com>2023-10-31 13:19:53 +1100
committerGitHub <noreply@github.com>2023-10-31 02:19:53 +0000
commit6979794bacaa4e3340870e24caa68b21fff32403 (patch)
treee68dbf5e29bad28ed4e38144bb1aadfbd656a98d /tmk_core/protocol
parent49fd13f596246c3d2079404ce2c2e14abcb78363 (diff)
Add "AC Next Keyboard Layout Select" consumer usage entry (macOS Globe key) (#22256)
Diffstat (limited to 'tmk_core/protocol')
-rw-r--r--tmk_core/protocol/report.h81
1 files changed, 41 insertions, 40 deletions
diff --git a/tmk_core/protocol/report.h b/tmk_core/protocol/report.h
index 9b612dd182..ec985e69ad 100644
--- a/tmk_core/protocol/report.h
+++ b/tmk_core/protocol/report.h
@@ -55,9 +55,9 @@ enum mouse_buttons {
55 */ 55 */
56enum consumer_usages { 56enum consumer_usages {
57 // 15.5 Display Controls 57 // 15.5 Display Controls
58 SNAPSHOT = 0x065, 58 SNAPSHOT = 0x065,
59 BRIGHTNESS_UP = 0x06F, // https://www.usb.org/sites/default/files/hutrr41_0.pdf 59 BRIGHTNESS_UP = 0x06F, // https://www.usb.org/sites/default/files/hutrr41_0.pdf
60 BRIGHTNESS_DOWN = 0x070, 60 BRIGHTNESS_DOWN = 0x070,
61 // 15.7 Transport Controls 61 // 15.7 Transport Controls
62 TRANSPORT_RECORD = 0x0B2, 62 TRANSPORT_RECORD = 0x0B2,
63 TRANSPORT_FAST_FORWARD = 0x0B3, 63 TRANSPORT_FAST_FORWARD = 0x0B3,
@@ -70,43 +70,44 @@ enum consumer_usages {
70 TRANSPORT_STOP_EJECT = 0x0CC, 70 TRANSPORT_STOP_EJECT = 0x0CC,
71 TRANSPORT_PLAY_PAUSE = 0x0CD, 71 TRANSPORT_PLAY_PAUSE = 0x0CD,
72 // 15.9.1 Audio Controls - Volume 72 // 15.9.1 Audio Controls - Volume
73 AUDIO_MUTE = 0x0E2, 73 AUDIO_MUTE = 0x0E2,
74 AUDIO_VOL_UP = 0x0E9, 74 AUDIO_VOL_UP = 0x0E9,
75 AUDIO_VOL_DOWN = 0x0EA, 75 AUDIO_VOL_DOWN = 0x0EA,
76 // 15.15 Application Launch Buttons 76 // 15.15 Application Launch Buttons
77 AL_CC_CONFIG = 0x183, 77 AL_CC_CONFIG = 0x183,
78 AL_EMAIL = 0x18A, 78 AL_EMAIL = 0x18A,
79 AL_CALCULATOR = 0x192, 79 AL_CALCULATOR = 0x192,
80 AL_LOCAL_BROWSER = 0x194, 80 AL_LOCAL_BROWSER = 0x194,
81 AL_LOCK = 0x19E, 81 AL_LOCK = 0x19E,
82 AL_CONTROL_PANEL = 0x19F, 82 AL_CONTROL_PANEL = 0x19F,
83 AL_ASSISTANT = 0x1CB, 83 AL_ASSISTANT = 0x1CB,
84 AL_KEYBOARD_LAYOUT = 0x1AE, 84 AL_KEYBOARD_LAYOUT = 0x1AE,
85 // 15.16 Generic GUI Application Controls 85 // 15.16 Generic GUI Application Controls
86 AC_NEW = 0x201, 86 AC_NEW = 0x201,
87 AC_OPEN = 0x202, 87 AC_OPEN = 0x202,
88 AC_CLOSE = 0x203, 88 AC_CLOSE = 0x203,
89 AC_EXIT = 0x204, 89 AC_EXIT = 0x204,
90 AC_MAXIMIZE = 0x205, 90 AC_MAXIMIZE = 0x205,
91 AC_MINIMIZE = 0x206, 91 AC_MINIMIZE = 0x206,
92 AC_SAVE = 0x207, 92 AC_SAVE = 0x207,
93 AC_PRINT = 0x208, 93 AC_PRINT = 0x208,
94 AC_PROPERTIES = 0x209, 94 AC_PROPERTIES = 0x209,
95 AC_UNDO = 0x21A, 95 AC_UNDO = 0x21A,
96 AC_COPY = 0x21B, 96 AC_COPY = 0x21B,
97 AC_CUT = 0x21C, 97 AC_CUT = 0x21C,
98 AC_PASTE = 0x21D, 98 AC_PASTE = 0x21D,
99 AC_SELECT_ALL = 0x21E, 99 AC_SELECT_ALL = 0x21E,
100 AC_FIND = 0x21F, 100 AC_FIND = 0x21F,
101 AC_SEARCH = 0x221, 101 AC_SEARCH = 0x221,
102 AC_HOME = 0x223, 102 AC_HOME = 0x223,
103 AC_BACK = 0x224, 103 AC_BACK = 0x224,
104 AC_FORWARD = 0x225, 104 AC_FORWARD = 0x225,
105 AC_STOP = 0x226, 105 AC_STOP = 0x226,
106 AC_REFRESH = 0x227, 106 AC_REFRESH = 0x227,
107 AC_BOOKMARKS = 0x22A, 107 AC_BOOKMARKS = 0x22A,
108 AC_MISSION_CONTROL = 0x29F, 108 AC_NEXT_KEYBOARD_LAYOUT_SELECT = 0x29D,
109 AC_LAUNCHPAD = 0x2A0 109 AC_DESKTOP_SHOW_ALL_WINDOWS = 0x29F,
110 AC_SOFT_KEY_LEFT = 0x2A0
110}; 111};
111 112
112/* Generic Desktop Page (0x01) 113/* Generic Desktop Page (0x01)
@@ -302,9 +303,9 @@ static inline uint16_t KEYCODE2CONSUMER(uint8_t key) {
302 case KC_WWW_FAVORITES: 303 case KC_WWW_FAVORITES:
303 return AC_BOOKMARKS; 304 return AC_BOOKMARKS;
304 case KC_MISSION_CONTROL: 305 case KC_MISSION_CONTROL:
305 return AC_MISSION_CONTROL; 306 return AC_DESKTOP_SHOW_ALL_WINDOWS;
306 case KC_LAUNCHPAD: 307 case KC_LAUNCHPAD:
307 return AC_LAUNCHPAD; 308 return AC_SOFT_KEY_LEFT;
308 default: 309 default:
309 return 0; 310 return 0;
310 } 311 }