X-Git-Url: https://git.friedersdorff.com/?a=blobdiff_plain;f=common%2Fhost.c;h=37f707d0b310a42ec9db70e83ed539c9c60e0729;hb=373ab0e7192811944786c095facb80938c33f1d5;hp=fddd5b6627fdad4411982bafbd3f70d6b135d5b1;hpb=4ae979f6ef8dbf9e1d1f35be15322ad6d02e2958;p=max%2Ftmk_keyboard.git
diff --git a/common/host.c b/common/host.c
index fddd5b66..37f707d0 100644
--- a/common/host.c
+++ b/common/host.c
@@ -17,7 +17,7 @@ along with this program. If not, see .
#include
#include
-#include "usb_keycodes.h"
+#include "keycode.h"
#include "host.h"
#include "util.h"
#include "debug.h"
@@ -69,6 +69,14 @@ void host_unregister_key(uint8_t key)
host_send_keyboard_report();
}
+void host_clear_all_keys_but_mods(void)
+{
+ for (int8_t i = 0; i < REPORT_KEYS; i++) {
+ keyboard_report->keys[i] = 0;
+ }
+ host_send_keyboard_report();
+}
+
/* keyboard report operations */
void host_add_key(uint8_t key)
{