summaryrefslogtreecommitdiffstats
path: root/users/alfrdmalr
diff options
context:
space:
mode:
authorRyan <fauxpark@gmail.com>2023-02-13 03:19:02 +1100
committerGitHub <noreply@github.com>2023-02-13 03:19:02 +1100
commitbbf7a20b33de2d203518687cb5cd1aa85005ea27 (patch)
treeee1a5c412a02021d085c81a26321c3424eca7022 /users/alfrdmalr
parentd10350cd2ceb2b9d80522cdec3ea908118f7fd35 (diff)
Refactor Leader key feature (#19632)
Co-authored-by: Drashna Jaelre <drashna@live.com>
Diffstat (limited to 'users/alfrdmalr')
-rw-r--r--users/alfrdmalr/alfrdmalr.c16
1 files changed, 6 insertions, 10 deletions
diff --git a/users/alfrdmalr/alfrdmalr.c b/users/alfrdmalr/alfrdmalr.c
index 18ce8bad7c..7bc04fb55c 100644
--- a/users/alfrdmalr/alfrdmalr.c
+++ b/users/alfrdmalr/alfrdmalr.c
@@ -7,7 +7,12 @@ uint16_t muse_counter = 0;
uint8_t muse_offset = 70;
uint16_t muse_tempo = 50;
-LEADER_EXTERNS();
+void leader_end_user(void) {
+ // reset keyboard to bootloader
+ if (leader_sequence_five_keys(KC_R, KC_E, KC_S, KC_E, KC_T)) {
+ reset_keyboard();
+ }
+}
void matrix_scan_user(void) {
#ifdef AUDIO_ENABLE
@@ -28,15 +33,6 @@ void matrix_scan_user(void) {
}
}
#endif
-
- LEADER_DICTIONARY() {
- leading = false;
- // reset keyboard to bootloader
- SEQ_FIVE_KEYS(KC_R, KC_E, KC_S, KC_E, KC_T) {
- reset_keyboard();
- }
- leader_end();
- }
}
bool syml_pressed = false;