Separated lua bindings from keyboard.c
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
/**
|
||||
/**
|
||||
* Copyright (c) 2016 rxi
|
||||
*
|
||||
* This library is free software; you can redistribute it and/or modify it
|
||||
@@ -8,7 +8,24 @@
|
||||
#ifndef KEYBOARD_H
|
||||
#define KEYBOARD_H
|
||||
|
||||
typedef struct {
|
||||
int type;
|
||||
unsigned code;
|
||||
const char *key;
|
||||
char text[64];
|
||||
int isrepeat;
|
||||
} keyboard_Event;
|
||||
|
||||
enum {
|
||||
KEYBOARD_KEYPRESS,
|
||||
KEYBOARD_KEYRELEASE,
|
||||
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);
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user