1
0
Fork 0

tap-dance: Restructure code and document in more detail (#16394)

This commit is contained in:
Jouke Witteveen 2022-06-13 22:12:55 +02:00 committed by GitHub
parent b17324498e
commit 1706da9054
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
52 changed files with 970 additions and 244 deletions

View file

@ -2,6 +2,7 @@
#undef TAPPING_TERM
#define TAPPING_TERM 200
#endif
#define TAPPING_TERM_PER_KEY
// Mouse Settings: Smoothing out mouse movement on keypress
#ifndef MOUSEKEY_INTERVAL
@ -18,4 +19,4 @@
#undef COMBO_TERM
#define COMBO_COUNT 5
#define COMBO_TERM 60
#endif
#endif

View file

@ -107,6 +107,16 @@ qk_tap_dance_action_t tap_dance_actions[] = {
[TD_GUI_GUISPC] = ACTION_TAP_DANCE_DOUBLE(KC_LGUI, LGUI(KC_SPC)),
// Advanced Tap Dances
[TD_COPY_PASTE_APP] = ACTION_TAP_DANCE_FN_ADVANCED_TIME(NULL, copy_paste_app_finished, copy_paste_app_reset, 300),
[TD_Y_NUMPAD] = ACTION_TAP_DANCE_FN_ADVANCED_TIME(NULL, y_numpad_finished, y_numpad_reset, 300),
};
[TD_COPY_PASTE_APP] = ACTION_TAP_DANCE_FN_ADVANCED(NULL, copy_paste_app_finished, copy_paste_app_reset),
[TD_Y_NUMPAD] = ACTION_TAP_DANCE_FN_ADVANCED(NULL, y_numpad_finished, y_numpad_reset),
};
uint16_t get_tapping_term(uint16_t keycode, keyrecord_t *record) {
switch (keycode) {
case TD(TD_COPY_PASTE_APP):
case TD(TD_Y_NUMPAD):
return 300;
default:
return TAPPING_TERM;
}
}