diff options
Diffstat (limited to 'keyboards/thevankeyboards/minivan')
4 files changed, 12 insertions, 12 deletions
diff --git a/keyboards/thevankeyboards/minivan/config.h b/keyboards/thevankeyboards/minivan/config.h index b3ba58985b..69e2bd07af 100644 --- a/keyboards/thevankeyboards/minivan/config.h +++ b/keyboards/thevankeyboards/minivan/config.h @@ -35,7 +35,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. */ #define MATRIX_ROW_PINS { D7, B5, F7, D4 } #define MATRIX_COL_PINS { D2, D3, D5, D6, B4, B6, F6, F5, F4, F1, F0, B3 } -#define UNUSED_PINS /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/thevankeyboards/minivan/keymaps/belak/config.h b/keyboards/thevankeyboards/minivan/keymaps/belak/config.h index 47d96a29d8..488ffa5418 100644 --- a/keyboards/thevankeyboards/minivan/keymaps/belak/config.h +++ b/keyboards/thevankeyboards/minivan/keymaps/belak/config.h @@ -4,5 +4,6 @@ #include "../../config.h" #define TAPPING_TERM 500 +#define PERMISSIVE_HOLD #endif diff --git a/keyboards/thevankeyboards/minivan/keymaps/belak/keymap.c b/keyboards/thevankeyboards/minivan/keymaps/belak/keymap.c index 437b1881a4..0ed709747a 100644 --- a/keyboards/thevankeyboards/minivan/keymaps/belak/keymap.c +++ b/keyboards/thevankeyboards/minivan/keymaps/belak/keymap.c @@ -22,6 +22,9 @@ #define TD_LCTL TD(BE_TD_CTL) #define TD_LALT TD(BE_TD_ALT) +#define ACTION_TAP_DANCE_MOD_TAP(mod) \ + { .fn = {mod_tap_fn, NULL, mod_reset_fn}, .user_data = (void *)&((uint8_t){mod}), } + enum belak_td { BE_TD_GUI = 0, BE_TD_CTL, @@ -32,15 +35,9 @@ void mod_tap_fn(qk_tap_dance_state_t *state, void *user_data); void mod_reset_fn(qk_tap_dance_state_t *state, void *user_data); qk_tap_dance_action_t tap_dance_actions[] = { - [BE_TD_GUI] = ACTION_TAP_DANCE_FN_ADVANCED(mod_tap_fn, NULL, mod_reset_fn), - [BE_TD_CTL] = ACTION_TAP_DANCE_FN_ADVANCED(mod_tap_fn, NULL, mod_reset_fn), - [BE_TD_ALT] = ACTION_TAP_DANCE_FN_ADVANCED(mod_tap_fn, NULL, mod_reset_fn), -}; - -uint16_t tap_dance_keys[] = { - [BE_TD_GUI] = KC_LGUI, - [BE_TD_CTL] = KC_LCTL, - [BE_TD_ALT] = KC_LALT, + [BE_TD_GUI] = ACTION_TAP_DANCE_MOD_TAP(KC_LGUI), + [BE_TD_CTL] = ACTION_TAP_DANCE_MOD_TAP(KC_LCTL), + [BE_TD_ALT] = ACTION_TAP_DANCE_MOD_TAP(KC_LALT), }; const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { @@ -74,7 +71,8 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { void mod_tap_fn(qk_tap_dance_state_t *state, void *user_data) { switch (state->count) { case 1: - register_mods(MOD_BIT(tap_dance_keys[state->keycode - QK_TAP_DANCE])); + uint8_t *mod = (uint8_t *)user_data; + register_mods(MOD_BIT(*mod)); send_keyboard_report(); break; case 2: @@ -90,8 +88,9 @@ void mod_tap_fn(qk_tap_dance_state_t *state, void *user_data) { } void mod_reset_fn(qk_tap_dance_state_t *state, void *user_data) { + uint8_t *mod = (uint8_t *)user_data; layer_off(_L1); layer_off(_L2); - unregister_mods(MOD_BIT(tap_dance_keys[state->keycode - QK_TAP_DANCE])); + unregister_mods(MOD_BIT(*mod)); send_keyboard_report(); } diff --git a/keyboards/thevankeyboards/minivan/keymaps/halvves/config.h b/keyboards/thevankeyboards/minivan/keymaps/halvves/config.h index 6be8d217bd..c6404f8ce5 100644 --- a/keyboards/thevankeyboards/minivan/keymaps/halvves/config.h +++ b/keyboards/thevankeyboards/minivan/keymaps/halvves/config.h @@ -1,6 +1,7 @@ #pragma once #define TAPPING_TERM 505 +#define PERMISSIVE_HOLD #define RETRO_TAPPING // smooth mousekeys (copied from the ergo ez config) |