summaryrefslogtreecommitdiff
path: root/app/include/zmk/hid.h
diff options
context:
space:
mode:
authorOkke Formsma <okke@formsma.nl>2021-01-22 17:00:19 +0100
committerPete Johanson <peter@peterjohanson.com>2021-01-24 23:30:41 -0500
commit7b7701ae90469b920cd78e2ab7aca0c470140b7a (patch)
treeb4fade597239b5f0df24197faea3413e305a636f /app/include/zmk/hid.h
parent0c30b49063c79be2416453f4544795922efad74f (diff)
feature(modifiers): add explicit modifiers
this makes LS(LEFT_CONTROL) work as if shift and control were both pressed explicitly. Previously, the left shift would have been released as soon as another key was pressed. The implicit behavior is useful in case of LS(NUMBER_1) when rolling over to other keys. Also see #361.
Diffstat (limited to 'app/include/zmk/hid.h')
-rw-r--r--app/include/zmk/hid.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/app/include/zmk/hid.h b/app/include/zmk/hid.h
index aca3cc4..5aa004c 100644
--- a/app/include/zmk/hid.h
+++ b/app/include/zmk/hid.h
@@ -169,6 +169,8 @@ struct zmk_hid_consumer_report {
zmk_mod_flags_t zmk_hid_get_explicit_mods();
int zmk_hid_register_mod(zmk_mod_t modifier);
int zmk_hid_unregister_mod(zmk_mod_t modifier);
+int zmk_hid_register_mods(zmk_mod_flags_t explicit_modifiers);
+int zmk_hid_unregister_mods(zmk_mod_flags_t explicit_modifiers);
int zmk_hid_implicit_modifiers_press(zmk_mod_flags_t implicit_modifiers);
int zmk_hid_implicit_modifiers_release();
int zmk_hid_keyboard_press(zmk_key_t key);