diff options
author | Joel Spadin <[email protected]> | 2022-10-29 23:17:12 -0500 |
---|---|---|
committer | Pete Johanson <[email protected]> | 2023-04-16 23:53:12 -0700 |
commit | e7a6e4016d757d37f0b8df28d7b78f38554e0b27 (patch) | |
tree | da1e287b9cf74cce9ba82b613b0d16aa443202a1 /app/src/behaviors | |
parent | 83a151890cd9491036ef2d73cd22db86a7a55f5c (diff) | |
download | zmk-e7a6e4016d757d37f0b8df28d7b78f38554e0b27.tar.gz zmk-e7a6e4016d757d37f0b8df28d7b78f38554e0b27.zip |
feat(behaviors): Add key position to key events
Extended the virtual key position system from combos so that each sensor
also gets a virtual key position. This allows sensor behaviors to use
the behavior queue API.
Diffstat (limited to 'app/src/behaviors')
-rw-r--r-- | app/src/behaviors/behavior_sensor_rotate_key_press.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/app/src/behaviors/behavior_sensor_rotate_key_press.c b/app/src/behaviors/behavior_sensor_rotate_key_press.c index ed6eedae9d..72e33ea46b 100644 --- a/app/src/behaviors/behavior_sensor_rotate_key_press.c +++ b/app/src/behaviors/behavior_sensor_rotate_key_press.c @@ -21,7 +21,8 @@ LOG_MODULE_DECLARE(zmk, CONFIG_ZMK_LOG_LEVEL); static int behavior_sensor_rotate_key_press_init(const struct device *dev) { return 0; }; static int on_sensor_binding_triggered(struct zmk_behavior_binding *binding, - const struct device *sensor, int64_t timestamp) { + const struct device *sensor, uint32_t virtual_key_position, + int64_t timestamp) { struct sensor_value value; int err; uint32_t keycode; |