aboutsummaryrefslogtreecommitdiff
path: root/tmk_core
diff options
context:
space:
mode:
Diffstat (limited to 'tmk_core')
-rw-r--r--tmk_core/common/keycode.h6
-rw-r--r--tmk_core/common/report.h7
2 files changed, 11 insertions, 2 deletions
diff --git a/tmk_core/common/keycode.h b/tmk_core/common/keycode.h
index 61642ae84..d6fef2beb 100644
--- a/tmk_core/common/keycode.h
+++ b/tmk_core/common/keycode.h
@@ -33,7 +33,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
33 33
34#define IS_SPECIAL(code) ((0xA5 <= (code) && (code) <= 0xDF) || (0xE8 <= (code) && (code) <= 0xFF)) 34#define IS_SPECIAL(code) ((0xA5 <= (code) && (code) <= 0xDF) || (0xE8 <= (code) && (code) <= 0xFF))
35#define IS_SYSTEM(code) (KC_PWR <= (code) && (code) <= KC_WAKE) 35#define IS_SYSTEM(code) (KC_PWR <= (code) && (code) <= KC_WAKE)
36#define IS_CONSUMER(code) (KC_MUTE <= (code) && (code) <= KC_MRWD) 36#define IS_CONSUMER(code) (KC_MUTE <= (code) && (code) <= KC_BRID)
37 37
38#define IS_FN(code) (KC_FN0 <= (code) && (code) <= KC_FN31) 38#define IS_FN(code) (KC_FN0 <= (code) && (code) <= KC_FN31)
39 39
@@ -170,6 +170,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
170#define KC_WFAV KC_WWW_FAVORITES 170#define KC_WFAV KC_WWW_FAVORITES
171#define KC_MFFD KC_MEDIA_FAST_FORWARD 171#define KC_MFFD KC_MEDIA_FAST_FORWARD
172#define KC_MRWD KC_MEDIA_REWIND 172#define KC_MRWD KC_MEDIA_REWIND
173#define KC_BRIU KC_BRIGHTNESS_UP
174#define KC_BRID KC_BRIGHTNESS_DOWN
173 175
174/* Mouse Keys */ 176/* Mouse Keys */
175#define KC_MS_U KC_MS_UP 177#define KC_MS_U KC_MS_UP
@@ -457,6 +459,8 @@ enum internal_special_keycodes {
457 KC_WWW_FAVORITES, 459 KC_WWW_FAVORITES,
458 KC_MEDIA_FAST_FORWARD, 460 KC_MEDIA_FAST_FORWARD,
459 KC_MEDIA_REWIND, 461 KC_MEDIA_REWIND,
462 KC_BRIGHTNESS_UP,
463 KC_BRIGHTNESS_DOWN,
460 464
461 /* Fn keys */ 465 /* Fn keys */
462 KC_FN0 = 0xC0, 466 KC_FN0 = 0xC0,
diff --git a/tmk_core/common/report.h b/tmk_core/common/report.h
index 5a1a6b19c..eb9afb727 100644
--- a/tmk_core/common/report.h
+++ b/tmk_core/common/report.h
@@ -38,6 +38,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
38 38
39/* Consumer Page(0x0C) 39/* Consumer Page(0x0C)
40 * following are supported by Windows: http://msdn.microsoft.com/en-us/windows/hardware/gg463372.aspx 40 * following are supported by Windows: http://msdn.microsoft.com/en-us/windows/hardware/gg463372.aspx
41 * see also https://docs.microsoft.com/en-us/windows-hardware/drivers/hid/display-brightness-control
41 */ 42 */
42#define AUDIO_MUTE 0x00E2 43#define AUDIO_MUTE 0x00E2
43#define AUDIO_VOL_UP 0x00E9 44#define AUDIO_VOL_UP 0x00E9
@@ -47,6 +48,8 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
47#define TRANSPORT_STOP 0x00B7 48#define TRANSPORT_STOP 0x00B7
48#define TRANSPORT_STOP_EJECT 0x00CC 49#define TRANSPORT_STOP_EJECT 0x00CC
49#define TRANSPORT_PLAY_PAUSE 0x00CD 50#define TRANSPORT_PLAY_PAUSE 0x00CD
51#define BRIGHTNESSUP 0x006F
52#define BRIGHTNESSDOWN 0x0070
50/* application launch */ 53/* application launch */
51#define AL_CC_CONFIG 0x0183 54#define AL_CC_CONFIG 0x0183
52#define AL_EMAIL 0x018A 55#define AL_EMAIL 0x018A
@@ -189,7 +192,9 @@ typedef struct {
189 (key == KC_WWW_FORWARD ? AC_FORWARD : \ 192 (key == KC_WWW_FORWARD ? AC_FORWARD : \
190 (key == KC_WWW_STOP ? AC_STOP : \ 193 (key == KC_WWW_STOP ? AC_STOP : \
191 (key == KC_WWW_REFRESH ? AC_REFRESH : \ 194 (key == KC_WWW_REFRESH ? AC_REFRESH : \
192 (key == KC_WWW_FAVORITES ? AC_BOOKMARKS : 0))))))))))))))))))))) 195 (key == KC_BRIGHTNESS_UP ? BRIGHTNESSUP : \
196 (key == KC_BRIGHTNESS_DOWN ? BRIGHTNESSDOWN : \
197 (key == KC_WWW_FAVORITES ? AC_BOOKMARKS : 0)))))))))))))))))))))))
193 198
194uint8_t has_anykey(report_keyboard_t* keyboard_report); 199uint8_t has_anykey(report_keyboard_t* keyboard_report);
195uint8_t get_first_key(report_keyboard_t* keyboard_report); 200uint8_t get_first_key(report_keyboard_t* keyboard_report);