From 782bf139a7570dffeb6613e6d3f29a71adb5ca9f Mon Sep 17 00:00:00 2001 From: sbosse Date: Mon, 14 Oct 2024 23:07:22 +0200 Subject: [PATCH] Mon 14 Oct 23:06:38 CEST 2024 --- kernel/event_queue.h | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 kernel/event_queue.h diff --git a/kernel/event_queue.h b/kernel/event_queue.h new file mode 100644 index 0000000..81ea009 --- /dev/null +++ b/kernel/event_queue.h @@ -0,0 +1,19 @@ +#ifndef EVENT_QUEUE_H +#define EVENT_QUEUE_H + +#include + +extern struct event_queue event_queue_root; + +struct event_queue * event_queue_create_root(); + +struct event_queue * event_queue_create(); +void event_queue_delete( struct event_queue *e); + +void event_queue_post( struct event_queue *q, struct event *e ); +int event_queue_read( struct event_queue *q, struct event *e, int size ); +int event_queue_read_nonblock( struct event_queue *q, struct event *e, int size ); + +void event_queue_post_root( uint16_t type, uint16_t code, int16_t x, int16_t y ); + +#endif