Browse Source

process_unicode: Make the startup overridable

Extract out the part of `qk_ucis_start` that inputs the placeholder
symbol, and make it weak, so it can be overridden.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
pull/635/head
Gergely Nagy 7 years ago
parent
commit
234dd276cf
2 changed files with 6 additions and 0 deletions
  1. +5
    -0
      quantum/process_keycode/process_unicode.c
  2. +1
    -0
      quantum/process_keycode/process_unicode.h

+ 5
- 0
quantum/process_keycode/process_unicode.c View File

@ -75,6 +75,11 @@ void qk_ucis_start(void) {
qk_ucis_state.count = 0;
qk_ucis_state.in_progress = true;
qk_ucis_start_user();
}
__attribute__((weak))
void qk_ucis_start_user(void) {
unicode_input_start();
register_hex(0x2328);
unicode_input_finish();


+ 1
- 0
quantum/process_keycode/process_unicode.h View File

@ -37,6 +37,7 @@ struct {
extern const qk_ucis_symbol_t ucis_symbol_table[];
void qk_ucis_start(void);
void qk_ucis_start_user(void);
void qk_ucis_symbol_fallback (void);
bool process_ucis (uint16_t keycode, keyrecord_t *record);


Loading…
Cancel
Save