2018-02-05 06:28:22 +00:00
|
|
|
#ifndef _VM_EVENT_H_
|
|
|
|
#define _VM_EVENT_H_
|
|
|
|
|
|
|
|
#include "vm_screen.h"
|
|
|
|
|
|
|
|
typedef struct {
|
|
|
|
SDL_Event event;
|
|
|
|
vm_screen *screen;
|
|
|
|
} vm_event;
|
|
|
|
|
2018-04-07 05:26:31 +00:00
|
|
|
typedef void (*vm_event_fn) (void *);
|
|
|
|
|
|
|
|
#define EVENT_DO(x) \
|
|
|
|
void x(void *_mach)
|
|
|
|
|
|
|
|
extern int vm_event_do(int);
|
2018-02-05 06:28:22 +00:00
|
|
|
extern void vm_event_keyboard(vm_event *);
|
2018-02-06 22:29:15 +00:00
|
|
|
extern void vm_event_keyboard_normal(vm_event *, char);
|
|
|
|
extern void vm_event_keyboard_special(vm_event *, char);
|
2018-04-07 05:26:31 +00:00
|
|
|
extern void vm_event_poll(vm_screen *);
|
2018-02-05 06:28:22 +00:00
|
|
|
|
|
|
|
#endif
|