summaryrefslogtreecommitdiff
path: root/app/src
diff options
context:
space:
mode:
authorinnovaker <66737976+innovaker@users.noreply.github.com>2020-12-19 17:33:15 +0000
committerPete Johanson <peter@peterjohanson.com>2020-12-28 10:20:12 -0500
commit87e7c04b00b2cb83540b757a8c909200cdb28255 (patch)
treec934a4ea1ae0b8cd47803c07a4effc80b3b04a5e /app/src
parent05b0d185a8c8c4eb19f63968e54f859a0f3e6484 (diff)
refactor(app): replace zmk_mod_flags with zmk_mod_flags_t
Aligns with typedef _t convention. PR: #531
Diffstat (limited to 'app/src')
-rw-r--r--app/src/hid.c4
-rw-r--r--app/src/hid_listener.c4
2 files changed, 4 insertions, 4 deletions
diff --git a/app/src/hid.c b/app/src/hid.c
index de853d8..37378b4 100644
--- a/app/src/hid.c
+++ b/app/src/hid.c
@@ -18,7 +18,7 @@ static struct zmk_hid_consumer_report consumer_report = {.report_id = 2, .body =
// Keep track of how often a modifier was pressed.
// Only release the modifier if the count is 0.
static int explicit_modifier_counts[8] = {0, 0, 0, 0, 0, 0, 0, 0};
-static zmk_mod_flags explicit_modifiers = 0;
+static zmk_mod_flags_t explicit_modifiers = 0;
#define SET_MODIFIERS(mods) \
{ \
@@ -67,7 +67,7 @@ int zmk_hid_unregister_mod(zmk_mod_t modifier) {
break; \
}
-int zmk_hid_implicit_modifiers_press(zmk_mod_flags implicit_modifiers) {
+int zmk_hid_implicit_modifiers_press(zmk_mod_flags_t implicit_modifiers) {
SET_MODIFIERS(explicit_modifiers | implicit_modifiers);
return 0;
}
diff --git a/app/src/hid_listener.c b/app/src/hid_listener.c
index cf8835a..80e9054 100644
--- a/app/src/hid_listener.c
+++ b/app/src/hid_listener.c
@@ -17,7 +17,7 @@ LOG_MODULE_DECLARE(zmk, CONFIG_ZMK_LOG_LEVEL);
#include <zmk/endpoints.h>
static int hid_listener_keycode_pressed(uint8_t usage_page, uint32_t keycode,
- zmk_mod_flags implicit_modifiers) {
+ zmk_mod_flags_t implicit_modifiers) {
int err;
LOG_DBG("usage_page 0x%02X keycode 0x%02X mods 0x%02X", usage_page, keycode,
implicit_modifiers);
@@ -42,7 +42,7 @@ static int hid_listener_keycode_pressed(uint8_t usage_page, uint32_t keycode,
}
static int hid_listener_keycode_released(uint8_t usage_page, uint32_t keycode,
- zmk_mod_flags implicit_modifiers) {
+ zmk_mod_flags_t implicit_modifiers) {
int err;
LOG_DBG("usage_page 0x%02X keycode 0x%02X mods 0x%02X", usage_page, keycode,
implicit_modifiers);