summaryrefslogtreecommitdiffstats
path: root/common/action.c
diff options
context:
space:
mode:
authortmk <nobody@nowhere>2013-07-23 07:54:14 +0900
committertmk <nobody@nowhere>2013-07-23 07:56:28 +0900
commit5b425731c5b662d107ba0f970a7ae7c7fe97d01b (patch)
tree25c8f53490930e4e70638211cec159f86e4018d5 /common/action.c
parent25aec56c082936a463d609357a04332c97c9940b (diff)
parent6aaa6e0ef9aa1e464b67723fd4cdd0d63b2c861d (diff)
Merge branch 'macro_mediakey'(Fix issue #42)
Diffstat (limited to 'common/action.c')
-rw-r--r--common/action.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/common/action.c b/common/action.c
index a42a7a4aee..c22f681fba 100644
--- a/common/action.c
+++ b/common/action.c
@@ -373,6 +373,12 @@ void register_code(uint8_t code)
host_add_mods(MOD_BIT(code));
host_send_keyboard_report();
}
+ else if IS_SYSTEM(code) {
+ host_system_send(KEYCODE2SYSTEM(code));
+ }
+ else if IS_CONSUMER(code) {
+ host_consumer_send(KEYCODE2CONSUMER(code));
+ }
}
void unregister_code(uint8_t code)
@@ -400,6 +406,12 @@ void unregister_code(uint8_t code)
host_del_mods(MOD_BIT(code));
host_send_keyboard_report();
}
+ else if IS_SYSTEM(code) {
+ host_system_send(0);
+ }
+ else if IS_CONSUMER(code) {
+ host_consumer_send(0);
+ }
}
void add_mods(uint8_t mods)