diff options
author | QMK Bot <hello@qmk.fm> | 2021-11-10 14:10:35 +0000 |
---|---|---|
committer | QMK Bot <hello@qmk.fm> | 2021-11-10 14:10:35 +0000 |
commit | ed48c0bd8b681123073da08da150c6bb4e7c2706 (patch) | |
tree | 152f2fcc0ba45799e2f0dece5930039abb3746d6 /users/drashna/drashna.c | |
parent | 5523f7093a797400fbd7367f9be50cb40ecdd68e (diff) | |
parent | 83ab7d41efc8b400ad2870be7f46e5435b8fd550 (diff) |
Merge remote-tracking branch 'origin/master' into develop
Diffstat (limited to 'users/drashna/drashna.c')
-rw-r--r-- | users/drashna/drashna.c | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/users/drashna/drashna.c b/users/drashna/drashna.c index 71539e8b80..7e07a2c7c5 100644 --- a/users/drashna/drashna.c +++ b/users/drashna/drashna.c @@ -259,3 +259,61 @@ void matrix_slave_scan_user(void) { matrix_slave_scan_keymap(); } #endif + +__attribute__((weak)) uint16_t get_tapping_term(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + default: + return TAPPING_TERM; + } +} + +__attribute__((weak)) bool get_permissive_hold(uint16_t keycode, keyrecord_t *record) { + // Immediately select the hold action when another key is tapped: + // return true; + // Do not select the hold action when another key is tapped. + // return false; + switch (keycode) { + default: + return false; + } +} + +__attribute__((weak)) bool get_hold_on_other_key_press(uint16_t keycode, keyrecord_t *record) { + // Immediately select the hold action when another key is pressed. + // return true; + // Do not select the hold action when another key is pressed. + // return false; + switch (keycode) { + case QK_LAYER_TAP ... QK_LAYER_TAP_MAX: + return true; + default: + return false; + } +} + +__attribute__((weak)) bool get_ignore_mod_tap_interrupt(uint16_t keycode, keyrecord_t *record) { + // Do not force the mod-tap key press to be handled as a modifier + // if any other key was pressed while the mod-tap key is held down. + // return true; + // Force the mod-tap key press to be handled as a modifier if any + // other key was pressed while the mod-tap key is held down. + // return false; + switch (keycode) { + default: + return true; + } +} + +__attribute__((weak)) bool get_tapping_force_hold(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + default: + return false; + } +} + +__attribute__((weak)) bool get_retro_tapping(uint16_t keycode, keyrecord_t *record) { + switch (keycode) { + default: + return false; + } +} |