Changed mouse and keyboard to push directly to event.c's queue

This commit is contained in:
rxi
2016-10-16 11:41:56 +01:00
parent a5c66d6154
commit de01a59eeb
8 changed files with 67 additions and 130 deletions

View File

@@ -8,24 +8,10 @@
#ifndef KEYBOARD_H
#define KEYBOARD_H
typedef struct {
int type;
unsigned code;
const char *key;
char text[64];
int isrepeat;
} keyboard_Event;
enum {
KEYBOARD_PRESSED,
KEYBOARD_RELEASED,
KEYBOARD_TEXTINPUT
};
int keyboard_init(void);
void keyboard_deinit(void);
void keyboard_setKeyRepeat(int allow);
int keyboard_isDown(const char *key);
int keyboard_poll(keyboard_Event *e);
void keyboard_update(void);
#endif