dev: implement input event hooks

This commit is contained in:
2023-06-11 16:46:58 +01:00
parent 3cc72f1f24
commit 7308fd98fb
3 changed files with 90 additions and 1 deletions

View File

@@ -2,6 +2,14 @@
#define SOCKS_INPUT_H_
#include <stdint.h>
#include <socks/queue.h>
#include <socks/status.h>
enum input_event_hook_flags {
INPUT_HOOK_SQUASH_EVENT = 0x01u,
};
struct device;
enum input_event_type {
INPUT_TYPE_UNKNOWN = 0x00u,
@@ -167,4 +175,10 @@ struct input_event {
};
};
struct input_event_hook {
void(*hook_callback)(struct device *, struct input_event *, enum input_event_hook_flags *, void *);
void *hook_arg;
struct queue_entry hook_head;
};
#endif