diff options
author | Ryan <fauxpark@gmail.com> | 2023-02-13 03:19:02 +1100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-02-13 03:19:02 +1100 |
commit | bbf7a20b33de2d203518687cb5cd1aa85005ea27 (patch) | |
tree | ee1a5c412a02021d085c81a26321c3424eca7022 /keyboards/maxr1998 | |
parent | d10350cd2ceb2b9d80522cdec3ea908118f7fd35 (diff) |
Refactor Leader key feature (#19632)
Co-authored-by: Drashna Jaelre <drashna@live.com>
Diffstat (limited to 'keyboards/maxr1998')
-rw-r--r-- | keyboards/maxr1998/phoebe/keymaps/default/keymap.c | 19 |
1 files changed, 6 insertions, 13 deletions
diff --git a/keyboards/maxr1998/phoebe/keymaps/default/keymap.c b/keyboards/maxr1998/phoebe/keymaps/default/keymap.c index 74a70f6174..b83d51f32a 100644 --- a/keyboards/maxr1998/phoebe/keymaps/default/keymap.c +++ b/keyboards/maxr1998/phoebe/keymaps/default/keymap.c @@ -130,18 +130,11 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) { return true; }; -LEADER_EXTERNS(); - -void matrix_scan_user(void) { - LEADER_DICTIONARY() { - leading = false; - leader_end(); - - SEQ_TWO_KEYS(KC_G, KC_P) { - SEND_STRING("git push"); - } - SEQ_THREE_KEYS(KC_G, KC_F, KC_P) { - SEND_STRING("git push --force-with-lease"); - } +void leader_end_user(void) { + if (leader_sequence_two_keys(KC_G, KC_P)) { + SEND_STRING("git push"); + } + if (leader_sequence_three_keys(KC_G, KC_F, KC_P)) { + SEND_STRING("git push --force-with-lease"); } } |