From 003db892adadb7b760f43411d7154fe60bf3556d Mon Sep 17 00:00:00 2001 From: Pete Johanson Date: Sun, 17 Jan 2021 16:36:01 -0500 Subject: refactor(core): Extra position state change data struct. * Separate header and data struct for the event. * Remove duplicate struct in split code. --- app/include/zmk/events/position_state_changed.h | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'app/include') diff --git a/app/include/zmk/events/position_state_changed.h b/app/include/zmk/events/position_state_changed.h index 0f1ac1b..7541b47 100644 --- a/app/include/zmk/events/position_state_changed.h +++ b/app/include/zmk/events/position_state_changed.h @@ -9,11 +9,15 @@ #include #include -struct position_state_changed { - struct zmk_event_header header; +struct zmk_position_state_changed_data { uint32_t position; bool state; int64_t timestamp; }; +struct position_state_changed { + struct zmk_event_header header; + struct zmk_position_state_changed_data data; +}; + ZMK_EVENT_DECLARE(position_state_changed); \ No newline at end of file -- cgit v1.2.3