summaryrefslogtreecommitdiff
path: root/keyboards/preonic
diff options
context:
space:
mode:
authorRyan <fauxpark@gmail.com>2022-12-15 07:40:25 +1100
committerGitHub <noreply@github.com>2022-12-14 12:40:25 -0800
commit1978007faefc0fb3af809ddf0d2ff1274e540570 (patch)
tree76e3d5ce69f8f4892602c5cfb6b54374642e7c55 /keyboards/preonic
parent83e8e5845a7136ade68bad82c156c70c071f9bf7 (diff)
Tap Dance: remove `qk_` prefix (#19313)
Diffstat (limited to 'keyboards/preonic')
-rw-r--r--keyboards/preonic/keymaps/choromanski/keymap.c2
-rwxr-xr-xkeyboards/preonic/keymaps/davidrambo/keymap.c6
-rw-r--r--keyboards/preonic/keymaps/egstad/keymap.c2
-rw-r--r--keyboards/preonic/keymaps/era1112/keymap.c14
-rw-r--r--keyboards/preonic/keymaps/mverteuil/keymap.c54
-rw-r--r--keyboards/preonic/keymaps/mverteuil_2x2u/keymap.c40
-rw-r--r--keyboards/preonic/keymaps/zach/zach_common_functions.c16
7 files changed, 67 insertions, 67 deletions
diff --git a/keyboards/preonic/keymaps/choromanski/keymap.c b/keyboards/preonic/keymaps/choromanski/keymap.c
index dd4a151980..ce7be97a57 100644
--- a/keyboards/preonic/keymaps/choromanski/keymap.c
+++ b/keyboards/preonic/keymaps/choromanski/keymap.c
@@ -21,7 +21,7 @@ enum {
};
//Tap Dance Definitions
-qk_tap_dance_action_t tap_dance_actions[] = {
+tap_dance_action_t tap_dance_actions[] = {
//Tap once for 1, twice for Grave
[G1] = ACTION_TAP_DANCE_DOUBLE(KC_1, KC_GRV),
//Tap once for [, twice for ]
diff --git a/keyboards/preonic/keymaps/davidrambo/keymap.c b/keyboards/preonic/keymaps/davidrambo/keymap.c
index 823bcb6862..aca8a7c1e3 100755
--- a/keyboards/preonic/keymaps/davidrambo/keymap.c
+++ b/keyboards/preonic/keymaps/davidrambo/keymap.c
@@ -156,7 +156,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
};
// Shift vs capslock function. From bbaserdem's Planck keymap.
-void caps_tap (qk_tap_dance_state_t *state, void *user_data) {
+void caps_tap (tap_dance_state_t *state, void *user_data) {
if (state->count == 1) {
register_code (KC_LSFT);
} else if (state->count == 2) {
@@ -164,7 +164,7 @@ void caps_tap (qk_tap_dance_state_t *state, void *user_data) {
register_code (KC_CAPS);
}
}
-void caps_tap_end (qk_tap_dance_state_t *state, void *user_data) {
+void caps_tap_end (tap_dance_state_t *state, void *user_data) {
if (state->count == 1) {
unregister_code (KC_LSFT);
} else {
@@ -173,7 +173,7 @@ void caps_tap_end (qk_tap_dance_state_t *state, void *user_data) {
}
//Tap Dance Definitions
-qk_tap_dance_action_t tap_dance_actions[] = {
+tap_dance_action_t tap_dance_actions[] = {
//Tap once for Shift, twice for Caps Lock
[SFT_LCK] = ACTION_TAP_DANCE_FN_ADVANCED( caps_tap, NULL, caps_tap_end )
};
diff --git a/keyboards/preonic/keymaps/egstad/keymap.c b/keyboards/preonic/keymaps/egstad/keymap.c
index 0ea9c339b1..4b1fad7323 100644
--- a/keyboards/preonic/keymaps/egstad/keymap.c
+++ b/keyboards/preonic/keymaps/egstad/keymap.c
@@ -219,7 +219,7 @@ layer_state_t layer_state_set_user(layer_state_t state) {
/* Tap Dance Definitions
========================================================================== */
-qk_tap_dance_action_t tap_dance_actions[] = {
+tap_dance_action_t tap_dance_actions[] = {
// Tap once for Left Brace, twice for Right Brace
[TD_BRC] = ACTION_TAP_DANCE_DOUBLE(KC_LBRC, KC_RBRC),
//Tap once for Minus, twice for Equal
diff --git a/keyboards/preonic/keymaps/era1112/keymap.c b/keyboards/preonic/keymaps/era1112/keymap.c
index 43c8ab9572..74ba6772d5 100644
--- a/keyboards/preonic/keymaps/era1112/keymap.c
+++ b/keyboards/preonic/keymaps/era1112/keymap.c
@@ -66,7 +66,7 @@ typedef struct {
td_state_t state;
} td_tap_t;
-td_state_t cur_dance(qk_tap_dance_state_t* state);
+td_state_t cur_dance(tap_dance_state_t* state);
/* Return an integer that corresponds to what kind of tap dance should be executed.
*
@@ -95,7 +95,7 @@ td_state_t cur_dance(qk_tap_dance_state_t* state);
* For the third point, there does exist the 'TD_DOUBLE_SINGLE_TAP', however this is not fully tested
*
*/
-td_state_t cur_dance(qk_tap_dance_state_t* state) {
+td_state_t cur_dance(tap_dance_state_t* state) {
if (state->count == 1) {
if (state->interrupted || !state->pressed) {
return TD_1_TAP;
@@ -117,15 +117,15 @@ td_state_t cur_dance(qk_tap_dance_state_t* state) {
//----------- 2tap capslock --------------//
//----------------------------------------//
-void twoCapsLock_finished(qk_tap_dance_state_t* state, void* user_data);
-void twoCapsLock_reset(qk_tap_dance_state_t* state, void* user_data);
+void twoCapsLock_finished(tap_dance_state_t* state, void* user_data);
+void twoCapsLock_reset(tap_dance_state_t* state, void* user_data);
static td_tap_t twoCapsLock_tap_state = {
.is_press_action = true,
.state = TD_NONE
};
-void twoCapsLock_finished(qk_tap_dance_state_t* state, void* user_data) {
+void twoCapsLock_finished(tap_dance_state_t* state, void* user_data) {
twoCapsLock_tap_state.state = cur_dance(state);
switch (twoCapsLock_tap_state.state) {
case TD_NONE: register_code(KC_LSFT); break;
@@ -142,7 +142,7 @@ void twoCapsLock_finished(qk_tap_dance_state_t* state, void* user_data) {
}
}
-void twoCapsLock_reset(qk_tap_dance_state_t* state, void* user_data) {
+void twoCapsLock_reset(tap_dance_state_t* state, void* user_data) {
switch (twoCapsLock_tap_state.state) {
case TD_UNKNOWN: unregister_code(KC_LSFT); break;
case TD_NONE: unregister_code(KC_LSFT); break;
@@ -202,7 +202,7 @@ enum custom_keycodes {
static bool blinky = false; // Track blinky behavior on/off for keycode
-qk_tap_dance_action_t tap_dance_actions[] = {
+tap_dance_action_t tap_dance_actions[] = {
[TD_2_CAPSLOCK] = ACTION_TAP_DANCE_FN_ADVANCED(NULL, twoCapsLock_finished, twoCapsLock_reset)
};
diff --git a/keyboards/preonic/keymaps/mverteuil/keymap.c b/keyboards/preonic/keymaps/mverteuil/keymap.c
index c54eff71d5..332e2877b2 100644
--- a/keyboards/preonic/keymaps/mverteuil/keymap.c
+++ b/keyboards/preonic/keymaps/mverteuil/keymap.c
@@ -75,17 +75,17 @@ typedef struct {
t_tap_state right_brackets;
} t_tap;
-t_tap_state get_tapdance_state(qk_tap_dance_state_t *state);
+t_tap_state get_tapdance_state(tap_dance_state_t *state);
-void td_numpad_funcrow_finished(qk_tap_dance_state_t *state, void *user_data);
-void td_numpad_funcrow_reset(qk_tap_dance_state_t *state, void *user_data);
-void td_brackets_left_finished(qk_tap_dance_state_t *state, void *user_data);
-void td_brackets_left_reset(qk_tap_dance_state_t *state, void *user_data);
-void td_brackets_right_finished(qk_tap_dance_state_t *state, void *user_data);
-void td_brackets_right_reset(qk_tap_dance_state_t *state, void *user_data);
+void td_numpad_funcrow_finished(tap_dance_state_t *state, void *user_data);
+void td_numpad_funcrow_reset(tap_dance_state_t *state, void *user_data);
+void td_brackets_left_finished(tap_dance_state_t *state, void *user_data);
+void td_brackets_left_reset(tap_dance_state_t *state, void *user_data);
+void td_brackets_right_finished(tap_dance_state_t *state, void *user_data);
+void td_brackets_right_reset(tap_dance_state_t *state, void *user_data);
/* Tap Dance Definitions */
-qk_tap_dance_action_t tap_dance_actions[] = {
+tap_dance_action_t tap_dance_actions[] = {
/* Tap once for left parenthesis, twice for left bracket, thrice for left brace */
[TD_BRACKETS_LEFT] = ACTION_TAP_DANCE_FN_ADVANCED(NULL, td_brackets_left_finished, td_brackets_left_reset),
/* Tap once for right parenthesis, twice for right bracket, thrice for right brace */
@@ -290,7 +290,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
};
/* Global TapDance State */
-static t_tap qk_tap_state = {
+static t_tap tap_state = {
.left_brackets = 0,
.numpad_funcrow = 0,
.right_brackets = 0,
@@ -300,7 +300,7 @@ float s_functionrow_on[][2] = LAYER_FUNCROW_ON_SONG;
float s_functionrow_off[][2] = LAYER_FUNCROW_OFF_SONG;
float s_numpad_toggle[][2] = LAYER_NMPAD_SONG;
-t_tap_state get_tapdance_state(qk_tap_dance_state_t *state) {
+t_tap_state get_tapdance_state(tap_dance_state_t *state) {
if (state->count == 1) {
if (state->interrupted || !state->pressed) {
return SINGLE_TAP;
@@ -323,9 +323,9 @@ t_tap_state get_tapdance_state(qk_tap_dance_state_t *state) {
return TAP_DANCE_NO_MATCH;
}
-void td_numpad_funcrow_finished(qk_tap_dance_state_t *state, void *user_data) {
- qk_tap_state.numpad_funcrow = get_tapdance_state(state);
- switch (qk_tap_state.numpad_funcrow) {
+void td_numpad_funcrow_finished(tap_dance_state_t *state, void *user_data) {
+ tap_state.numpad_funcrow = get_tapdance_state(state);
+ switch (tap_state.numpad_funcrow) {
case SINGLE_TAP ... SINGLE_HOLD:
layer_on(_NUMPAD);
PLAY_SONG(s_numpad_toggle);
@@ -347,8 +347,8 @@ void td_numpad_funcrow_finished(qk_tap_dance_state_t *state, void *user_data) {
}
}
-void td_numpad_funcrow_reset(qk_tap_dance_state_t *state, void *user_data) {
- switch (qk_tap_state.numpad_funcrow) {
+void td_numpad_funcrow_reset(tap_dance_state_t *state, void *user_data) {
+ switch (tap_state.numpad_funcrow) {
case SINGLE_HOLD:
layer_off(_NUMPAD);
break;
@@ -360,9 +360,9 @@ void td_numpad_funcrow_reset(qk_tap_dance_state_t *state, void *user_data) {
}
}
-void td_brackets_left_finished(qk_tap_dance_state_t *state, void *user_data) {
- qk_tap_state.left_brackets = get_tapdance_state(state);
- switch (qk_tap_state.left_brackets) {
+void td_brackets_left_finished(tap_dance_state_t *state, void *user_data) {
+ tap_state.left_brackets = get_tapdance_state(state);
+ switch (tap_state.left_brackets) {
case SINGLE_TAP:
register_code16(KC_LEFT_PAREN);
break;
@@ -377,8 +377,8 @@ void td_brackets_left_finished(qk_tap_dance_state_t *state, void *user_data) {
}
}
-void td_brackets_left_reset(qk_tap_dance_state_t *state, void *user_data) {
- switch (qk_tap_state.left_brackets) {
+void td_brackets_left_reset(tap_dance_state_t *state, void *user_data) {
+ switch (tap_state.left_brackets) {
case SINGLE_TAP:
unregister_code16(KC_LEFT_PAREN);
break;
@@ -391,12 +391,12 @@ void td_brackets_left_reset(qk_tap_dance_state_t *state, void *user_data) {
default:
break;
}
- qk_tap_state.left_brackets = 0;
+ tap_state.left_brackets = 0;
}
-void td_brackets_right_finished(qk_tap_dance_state_t *state, void *user_data) {
- qk_tap_state.right_brackets = get_tapdance_state(state);
- switch (qk_tap_state.right_brackets) {
+void td_brackets_right_finished(tap_dance_state_t *state, void *user_data) {
+ tap_state.right_brackets = get_tapdance_state(state);
+ switch (tap_state.right_brackets) {
case SINGLE_TAP:
register_code16(KC_RIGHT_PAREN);
break;
@@ -411,8 +411,8 @@ void td_brackets_right_finished(qk_tap_dance_state_t *state, void *user_data) {
}
}
-void td_brackets_right_reset(qk_tap_dance_state_t *state, void *user_data) {
- switch (qk_tap_state.right_brackets) {
+void td_brackets_right_reset(tap_dance_state_t *state, void *user_data) {
+ switch (tap_state.right_brackets) {
case SINGLE_TAP:
unregister_code16(KC_RIGHT_PAREN);
break;
@@ -425,7 +425,7 @@ void td_brackets_right_reset(qk_tap_dance_state_t *state, void *user_data) {
default:
break;
}
- qk_tap_state.right_brackets = 0;
+ tap_state.right_brackets = 0;
}
bool muse_mode = false;
diff --git a/keyboards/preonic/keymaps/mverteuil_2x2u/keymap.c b/keyboards/preonic/keymaps/mverteuil_2x2u/keymap.c
index a269519339..c6cad0fe5f 100644
--- a/keyboards/preonic/keymaps/mverteuil_2x2u/keymap.c
+++ b/keyboards/preonic/keymaps/mverteuil_2x2u/keymap.c
@@ -78,15 +78,15 @@ typedef struct {
t_tap_state right_brackets;
} t_tap;
-t_tap_state get_tapdance_state(qk_tap_dance_state_t *state);
+t_tap_state get_tapdance_state(tap_dance_state_t *state);
-void td_brackets_left_finished(qk_tap_dance_state_t *state, void *user_data);
-void td_brackets_left_reset(qk_tap_dance_state_t *state, void *user_data);
-void td_brackets_right_finished(qk_tap_dance_state_t *state, void *user_data);
-void td_brackets_right_reset(qk_tap_dance_state_t *state, void *user_data);
+void td_brackets_left_finished(tap_dance_state_t *state, void *user_data);
+void td_brackets_left_reset(tap_dance_state_t *state, void *user_data);
+void td_brackets_right_finished(tap_dance_state_t *state, void *user_data);
+void td_brackets_right_reset(tap_dance_state_t *state, void *user_data);
/* Tap Dance Definitions */
-qk_tap_dance_action_t tap_dance_actions[] = {
+tap_dance_action_t tap_dance_actions[] = {
/* Tap once for left parenthesis, twice for left bracket, thrice for left brace */
[TD_BRACKETS_LEFT] = ACTION_TAP_DANCE_FN_ADVANCED(NULL, td_brackets_left_finished, td_brackets_left_reset),
/* Tap once for right parenthesis, twice for right bracket, thrice for right brace */
@@ -266,14 +266,14 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) {
};
/* Global TapDance State */
-static t_tap qk_tap_state = {
+static t_tap tap_state = {
.left_brackets = 0,
.right_brackets = 0,
};
float s_numpad_toggle[][2] = LAYER_NMPAD_SONG;
-t_tap_state get_tapdance_state(qk_tap_dance_state_t *state) {
+t_tap_state get_tapdance_state(tap_dance_state_t *state) {
if (state->count == 1) {
if (state->interrupted || !state->pressed) {
return SINGLE_TAP;
@@ -296,9 +296,9 @@ t_tap_state get_tapdance_state(qk_tap_dance_state_t *state) {
return TAP_DANCE_NO_MATCH;
}
-void td_brackets_left_finished(qk_tap_dance_state_t *state, void *user_data) {
- qk_tap_state.left_brackets = get_tapdance_state(state);
- switch (qk_tap_state.left_brackets) {
+void td_brackets_left_finished(tap_dance_state_t *state, void *user_data) {
+ tap_state.left_brackets = get_tapdance_state(state);
+ switch (tap_state.left_brackets) {
case SINGLE_TAP:
register_code16(KC_LEFT_PAREN);
break;
@@ -313,8 +313,8 @@ void td_brackets_left_finished(qk_tap_dance_state_t *state, void *user_data) {
}
}
-void td_brackets_left_reset(qk_tap_dance_state_t *state, void *user_data) {
- switch (qk_tap_state.left_brackets) {
+void td_brackets_left_reset(tap_dance_state_t *state, void *user_data) {
+ switch (tap_state.left_brackets) {
case SINGLE_TAP:
unregister_code16(KC_LEFT_PAREN);
break;
@@ -327,12 +327,12 @@ void td_brackets_left_reset(qk_tap_dance_state_t *state, void *user_data) {
default:
break;
}
- qk_tap_state.left_brackets = 0;
+ tap_state.left_brackets = 0;
}
-void td_brackets_right_finished(qk_tap_dance_state_t *state, void *user_data) {
- qk_tap_state.right_brackets = get_tapdance_state(state);
- switch (qk_tap_state.right_brackets) {
+void td_brackets_right_finished(tap_dance_state_t *state, void *user_data) {
+ tap_state.right_brackets = get_tapdance_state(state);
+ switch (tap_state.right_brackets) {
case SINGLE_TAP:
register_code16(KC_RIGHT_PAREN);
break;
@@ -347,8 +347,8 @@ void td_brackets_right_finished(qk_tap_dance_state_t *state, void *user_data) {
}
}
-void td_brackets_right_reset(qk_tap_dance_state_t *state, void *user_data) {
- switch (qk_tap_state.right_brackets) {
+void td_brackets_right_reset(tap_dance_state_t *state, void *user_data) {
+ switch (tap_state.right_brackets) {
case SINGLE_TAP:
unregister_code16(KC_RIGHT_PAREN);
break;
@@ -361,7 +361,7 @@ void td_brackets_right_reset(qk_tap_dance_state_t *state, void *user_data) {
default:
break;
}
- qk_tap_state.right_brackets = 0;
+ tap_state.right_brackets = 0;
}
bool muse_mode = false;
diff --git a/keyboards/preonic/keymaps/zach/zach_common_functions.c b/keyboards/preonic/keymaps/zach/zach_common_functions.c
index 7a594b567f..b6e8d9be47 100644
--- a/keyboards/preonic/keymaps/zach/zach_common_functions.c
+++ b/keyboards/preonic/keymaps/zach/zach_common_functions.c
@@ -68,7 +68,7 @@ float unilin[][2] = SONG(UNICODE_LINUX);
#ifdef TAP_DANCE_ENABLE
#define TAPPING_TERM 200
-void dance_raise_press(qk_tap_dance_state_t *state, void *user_data){// Called on each tap
+void dance_raise_press(tap_dance_state_t *state, void *user_data){// Called on each tap
switch(state->count){ // Only turn the layer on once
case 1:
layer_off(_UNICODES);
@@ -77,7 +77,7 @@ void dance_raise_press(qk_tap_dance_state_t *state, void *user_data){// Called o
break;
}
};
-void dance_raise_lift(qk_tap_dance_state_t *state, void *user_data){ // Called on release
+void dance_raise_lift(tap_dance_state_t *state, void *user_data){ // Called on release
switch(state->count){
case 1: // Normal action. Turn off layers
layer_off(_RAISE);
@@ -87,7 +87,7 @@ void dance_raise_lift(qk_tap_dance_state_t *state, void *user_data){ // Called o
}
};
/////////////////////////////////////////////////////////////////////
-void dance_lower_press(qk_tap_dance_state_t *state, void *user_data){// Called on tap
+void dance_lower_press(tap_dance_state_t *state, void *user_data){// Called on tap
switch(state->count){
case 1: // Turn on lower
layer_off(_UNICODES);
@@ -96,7 +96,7 @@ void dance_lower_press(qk_tap_dance_state_t *state, void *user_data){// Called o
break;
}
};
-void dance_lower_lift(qk_tap_dance_state_t *state, void *user_data){ // Called on release
+void dance_lower_lift(tap_dance_state_t *state, void *user_data){ // Called on release
switch(state->count){
case 1: // Normal action. Turn off layers
layer_off(_LOWER);
@@ -114,12 +114,12 @@ void dance_lower_lift(qk_tap_dance_state_t *state, void *user_data){ // Called o
}
};
/////////////////////////////////////////////////////////////////////
-void dance_super_press(qk_tap_dance_state_t *state, void *user_data){ // Called on down
+void dance_super_press(tap_dance_state_t *state, void *user_data){ // Called on down
if(state->count == 1){
register_code(KC_LGUI);
}
}
-void dance_super_done(qk_tap_dance_state_t *state, void *user_data){ // Called on timeout
+void dance_super_done(tap_dance_state_t *state, void *user_data){ // Called on timeout
switch(state->count){
case 2:
register_code(KC_LGUI);
@@ -128,11 +128,11 @@ void dance_super_done(qk_tap_dance_state_t *state, void *user_data){ // Calle
break;
}
}
-void dance_super_lift(qk_tap_dance_state_t *state, void *user_data){ // Called on up
+void dance_super_lift(tap_dance_state_t *state, void *user_data){ // Called on up
unregister_code(KC_LGUI);
}
-qk_tap_dance_action_t tap_dance_actions[] = {
+tap_dance_action_t tap_dance_actions[] = {
[RAI] = ACTION_TAP_DANCE_FN_ADVANCED(dance_raise_press, NULL, dance_raise_lift),
[LOW] = ACTION_TAP_DANCE_FN_ADVANCED(dance_lower_press, NULL, dance_lower_lift),
[SUP] = ACTION_TAP_DANCE_FN_ADVANCED(dance_super_press, dance_super_done, dance_super_lift)