diff --git a/keyboards/whitefox/keymaps/konstantin/keymap.c b/keyboards/whitefox/keymaps/konstantin/keymap.c index ac03d675597..07e6b8cbc15 100644 --- a/keyboards/whitefox/keymaps/konstantin/keymap.c +++ b/keyboards/whitefox/keymaps/konstantin/keymap.c @@ -38,7 +38,7 @@ bool process_record_user(uint16_t keycode, keyrecord_t *record) { return false; case CYCLEUC: - if (record->event.pressed) { cycle_unicode_input_mode(); } + if (record->event.pressed) { cycle_unicode_input_mode(+1); } return false; case NUMPAD: diff --git a/quantum/process_keycode/process_unicode_common.c b/quantum/process_keycode/process_unicode_common.c index e173e634998..0cdfe7939ed 100644 --- a/quantum/process_keycode/process_unicode_common.c +++ b/quantum/process_keycode/process_unicode_common.c @@ -56,9 +56,9 @@ void unicode_input_mode_init(void) { dprintf("input_mode init to: %u\n", unicode_config.input_mode); } -void cycle_unicode_input_mode(void) { +void cycle_unicode_input_mode(uint8_t offset) { #if UNICODE_SELECTED_MODES != -1 - selected_index = (selected_index + 1) % selected_count; + selected_index = (selected_index + offset) % selected_count; unicode_config.input_mode = selected[selected_index]; #if UNICODE_CYCLE_PERSIST persist_unicode_input_mode(); diff --git a/quantum/process_keycode/process_unicode_common.h b/quantum/process_keycode/process_unicode_common.h index 4d610273959..b9038f2e882 100644 --- a/quantum/process_keycode/process_unicode_common.h +++ b/quantum/process_keycode/process_unicode_common.h @@ -49,7 +49,7 @@ extern unicode_config_t unicode_config; void set_unicode_input_mode(uint8_t os_target); uint8_t get_unicode_input_mode(void); void unicode_input_mode_init(void); -void cycle_unicode_input_mode(void); +void cycle_unicode_input_mode(uint8_t offset); void persist_unicode_input_mode(void); void unicode_input_start(void);