refactor(core): Extra position state change data struct.
* Separate header and data struct for the event. * Remove duplicate struct in split code.
This commit is contained in:
parent
95acbd8859
commit
003db892ad
6 changed files with 31 additions and 34 deletions
|
|
@ -9,11 +9,15 @@
|
|||
#include <zephyr.h>
|
||||
#include <zmk/event_manager.h>
|
||||
|
||||
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);
|
||||
Loading…
Add table
Add a link
Reference in a new issue