diff options
| author | Alex Ong <the.onga@gmail.com> | 2019-01-04 19:39:14 +1100 |
|---|---|---|
| committer | Alex Ong <the.onga@gmail.com> | 2019-01-04 19:39:14 +1100 |
| commit | 47c91fc7f75ae0a477e55b687aa0fc30da0a283c (patch) | |
| tree | 65ad39452748ff2e6d4a83ce54ede6ca22c9ada9 /quantum/process_keycode/process_tap_dance.c | |
| parent | ac9b88e8ccbbf38762871504cd827ff0d941c426 (diff) | |
| parent | 563ce3f225d981ce460c12ca5130dfe47af41df0 (diff) | |
| download | qmk_firmware-47c91fc7f75ae0a477e55b687aa0fc30da0a283c.tar.gz qmk_firmware-47c91fc7f75ae0a477e55b687aa0fc30da0a283c.zip | |
Merge branch 'master' of https://github.com/qmk/qmk_firmware
Diffstat (limited to 'quantum/process_keycode/process_tap_dance.c')
| -rw-r--r-- | quantum/process_keycode/process_tap_dance.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/quantum/process_keycode/process_tap_dance.c b/quantum/process_keycode/process_tap_dance.c index 833780691..16d33ddde 100644 --- a/quantum/process_keycode/process_tap_dance.c +++ b/quantum/process_keycode/process_tap_dance.c | |||
| @@ -16,6 +16,10 @@ | |||
| 16 | #include "quantum.h" | 16 | #include "quantum.h" |
| 17 | #include "action_tapping.h" | 17 | #include "action_tapping.h" |
| 18 | 18 | ||
| 19 | #ifndef TAPPING_TERM | ||
| 20 | #define TAPPING_TERM 200 | ||
| 21 | #endif | ||
| 22 | |||
| 19 | #ifndef NO_ACTION_ONESHOT | 23 | #ifndef NO_ACTION_ONESHOT |
| 20 | uint8_t get_oneshot_mods(void); | 24 | uint8_t get_oneshot_mods(void); |
| 21 | #endif | 25 | #endif |
| @@ -127,6 +131,7 @@ void preprocess_tap_dance(uint16_t keycode, keyrecord_t *record) { | |||
| 127 | if (keycode == action->state.keycode && keycode == last_td) | 131 | if (keycode == action->state.keycode && keycode == last_td) |
| 128 | continue; | 132 | continue; |
| 129 | action->state.interrupted = true; | 133 | action->state.interrupted = true; |
| 134 | action->state.interrupting_keycode = keycode; | ||
| 130 | process_tap_dance_action_on_dance_finished (action); | 135 | process_tap_dance_action_on_dance_finished (action); |
| 131 | reset_tap_dance (&action->state); | 136 | reset_tap_dance (&action->state); |
| 132 | } | 137 | } |
| @@ -205,5 +210,6 @@ void reset_tap_dance (qk_tap_dance_state_t *state) { | |||
| 205 | state->count = 0; | 210 | state->count = 0; |
| 206 | state->interrupted = false; | 211 | state->interrupted = false; |
| 207 | state->finished = false; | 212 | state->finished = false; |
| 213 | state->interrupting_keycode = 0; | ||
| 208 | last_td = 0; | 214 | last_td = 0; |
| 209 | } | 215 | } |
