diff options
| author | lambdalisue <lambdalisue@hashnote.net> | 2017-02-14 14:12:54 +0900 |
|---|---|---|
| committer | lambdalisue <lambdalisue@hashnote.net> | 2017-02-14 14:12:54 +0900 |
| commit | 64f9779fe54facecdef9d1a6a7c1d893f79ca20e (patch) | |
| tree | 0df64f7cccf718bc2fa01a928006a8ee1ee0f242 /tmk_core | |
| parent | fd2925efbac0d7963f3d267dd5264f08a0a4e9dc (diff) | |
| download | qmk_firmware-64f9779fe54facecdef9d1a6a7c1d893f79ca20e.tar.gz qmk_firmware-64f9779fe54facecdef9d1a6a7c1d893f79ca20e.zip | |
Add TAPPING_FORCE_HOLD to regulate behaviour
See #889 for the detail.
Diffstat (limited to 'tmk_core')
| -rw-r--r-- | tmk_core/common/action_tapping.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/tmk_core/common/action_tapping.c b/tmk_core/common/action_tapping.c index e16e11be7..66044d8bc 100644 --- a/tmk_core/common/action_tapping.c +++ b/tmk_core/common/action_tapping.c | |||
| @@ -228,6 +228,7 @@ bool process_tapping(keyrecord_t *keyp) | |||
| 228 | if (WITHIN_TAPPING_TERM(event)) { | 228 | if (WITHIN_TAPPING_TERM(event)) { |
| 229 | if (event.pressed) { | 229 | if (event.pressed) { |
| 230 | if (IS_TAPPING_KEY(event.key)) { | 230 | if (IS_TAPPING_KEY(event.key)) { |
| 231 | #ifndef TAPPING_FORCE_HOLD | ||
| 231 | if (!tapping_key.tap.interrupted && tapping_key.tap.count > 0) { | 232 | if (!tapping_key.tap.interrupted && tapping_key.tap.count > 0) { |
| 232 | // sequential tap. | 233 | // sequential tap. |
| 233 | keyp->tap = tapping_key.tap; | 234 | keyp->tap = tapping_key.tap; |
| @@ -237,11 +238,11 @@ bool process_tapping(keyrecord_t *keyp) | |||
| 237 | tapping_key = *keyp; | 238 | tapping_key = *keyp; |
| 238 | debug_tapping_key(); | 239 | debug_tapping_key(); |
| 239 | return true; | 240 | return true; |
| 240 | } else { | ||
| 241 | // FIX: start new tap again | ||
| 242 | tapping_key = *keyp; | ||
| 243 | return true; | ||
| 244 | } | 241 | } |
| 242 | #endif | ||
| 243 | // FIX: start new tap again | ||
| 244 | tapping_key = *keyp; | ||
| 245 | return true; | ||
| 245 | } else if (is_tap_key(event.key)) { | 246 | } else if (is_tap_key(event.key)) { |
| 246 | // Sequential tap can be interfered with other tap key. | 247 | // Sequential tap can be interfered with other tap key. |
| 247 | debug("Tapping: Start with interfering other tap.\n"); | 248 | debug("Tapping: Start with interfering other tap.\n"); |
