From 6ec87c5d265dd34e61f8d9574b3054ed7b9c463d Mon Sep 17 00:00:00 2001 From: Takeshi Nishio Date: Wed, 26 Aug 2020 06:14:56 +0900 Subject: [PATCH] =?UTF-8?q?Update=20=E3=82=BF=E3=83=83=E3=83=97=E3=83=80?= =?UTF-8?q?=E3=83=B3=E3=82=B9=E3=81=AE=E7=8A=B6=E6=85=8B=E5=88=A4=E5=88=A5?= =?UTF-8?q?=E3=82=92=E3=80=81Single,Double,Triple,Hold=E3=81=AE4=E3=81=A4?= =?UTF-8?q?=E3=81=AE=E3=82=B9=E3=83=86=E3=83=BC=E3=82=BF=E3=82=B9=E3=81=AB?= =?UTF-8?q?=E3=81=BE=E3=81=A8=E3=82=81=E3=81=9F=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- keyboards/jones/v.0.2/keymaps/default/keymap.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/keyboards/jones/v.0.2/keymaps/default/keymap.c b/keyboards/jones/v.0.2/keymaps/default/keymap.c index 0f7a7d789ba..5624ef7b6f0 100644 --- a/keyboards/jones/v.0.2/keymaps/default/keymap.c +++ b/keyboards/jones/v.0.2/keymaps/default/keymap.c @@ -61,8 +61,9 @@ enum tap_dances{ // for toggle layer by ESC enum { SINGLE_TAP = 1, - SINGLE_HOLD, - TRIPLE_TAP + DOUBLE_TAP, + TRIPLE_TAP, + TAP_HOLD, }; // Declare the functions to be used with your tap dance key(s) @@ -426,9 +427,12 @@ typedef struct { // Determine the current tap dance state uint8_t cur_dance(qk_tap_dance_state_t *state) { - if (state->count < 3) { + if (state->count == 1) { if (!state->pressed) return SINGLE_TAP; - else return SINGLE_HOLD; + else return TAP_HOLD; + } else if (state->count == 2) { + if (!state->pressed) return DOUBLE_TAP; + else return TAP_HOLD; } else if (state->count == 3) return TRIPLE_TAP; else return 8; }