summaryrefslogtreecommitdiff
path: root/app/src/behaviors/behavior_hold_tap.c
diff options
context:
space:
mode:
authorPete Johanson <peter@peterjohanson.com>2020-10-26 00:30:24 -0400
committerPete Johanson <peter@peterjohanson.com>2020-11-05 14:55:40 -0500
commiteff1b8223b5010d526914530c5d1d469eff356df (patch)
tree70a7d7c603d0c384110fec9bc4b5dd7b01896a7f /app/src/behaviors/behavior_hold_tap.c
parent5f83568a93bbbf07bed6e710ba8c44e45b955ec5 (diff)
refactor(keys): Unify usage page.
* Remove need for separate `&cp` behavior, but keep it for now for backward compat. * Refactor sensor inc/dec as well.
Diffstat (limited to 'app/src/behaviors/behavior_hold_tap.c')
-rw-r--r--app/src/behaviors/behavior_hold_tap.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/src/behaviors/behavior_hold_tap.c b/app/src/behaviors/behavior_hold_tap.c
index c53750a..1dc665d 100644
--- a/app/src/behaviors/behavior_hold_tap.c
+++ b/app/src/behaviors/behavior_hold_tap.c
@@ -429,8 +429,8 @@ static int position_state_changed_listener(const struct zmk_event_header *eh) {
}
static inline bool only_mods(struct keycode_state_changed *ev) {
- return ev->usage_page == HID_USAGE_KEY && ev->keycode >= LEFT_CONTROL &&
- ev->keycode <= RIGHT_GUI;
+ return ev->usage_page == HID_USAGE_KEY && ev->keycode >= HID_USAGE_KEY_KEYBOARD_LEFTCONTROL &&
+ ev->keycode <= HID_USAGE_KEY_KEYBOARD_RIGHT_GUI;
}
static int keycode_state_changed_listener(const struct zmk_event_header *eh) {