diff options
author | Priyadi Iman Nurcahyo <priyadi@priyadi.net> | 2017-02-13 14:55:35 +0700 |
---|---|---|
committer | Priyadi Iman Nurcahyo <priyadi@priyadi.net> | 2017-02-13 14:55:35 +0700 |
commit | 8c93c5d9ab8a0a69d84f707db71f417b66402693 (patch) | |
tree | 47f9577431d21f7c54ed8ff0d68e77f4a42123a9 /quantum/quantum.c | |
parent | c68e596f32c5d450a714627871408407e9988ef7 (diff) | |
download | firmware-8c93c5d9ab8a0a69d84f707db71f417b66402693.tar.gz firmware-8c93c5d9ab8a0a69d84f707db71f417b66402693.tar.bz2 firmware-8c93c5d9ab8a0a69d84f707db71f417b66402693.zip |
Add keycodes to turn on, turn off and toggle faux clicky
Diffstat (limited to 'quantum/quantum.c')
-rw-r--r-- | quantum/quantum.c | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/quantum/quantum.c b/quantum/quantum.c index 45ea8cb73..2088c10c9 100644 --- a/quantum/quantum.c +++ b/quantum/quantum.c @@ -7,6 +7,10 @@ #define TAPPING_TERM 200 #endif +#ifdef FAUXCLICKY_ENABLE +#include "fauxclicky.h" +#endif + static void do_code16 (uint16_t code, void (*f) (uint8_t)) { switch (code) { case QK_MODS ... QK_MODS_MAX: @@ -196,6 +200,26 @@ bool process_record_quantum(keyrecord_t *record) { } return false; break; + #ifdef FAUXCLICKY_ENABLE + case FC_TOG: + if (record->event.pressed) { + FAUXCLICKY_TOGGLE; + } + return false; + break; + case FC_ON: + if (record->event.pressed) { + FAUXCLICKY_ON; + } + return false; + break; + case FC_OFF: + if (record->event.pressed) { + FAUXCLICKY_OFF; + } + return false; + break; + #endif #ifdef RGBLIGHT_ENABLE case RGB_TOG: if (record->event.pressed) { |