mirror of
https://codeberg.org/hkzlab/TK2048.git
synced 2026-01-12 04:13:03 +11:00
Replace enums with simple defs, replace kb routine with asm
calypsi uses "int" as the type for enums, also replace the basic keyboard routine for key reading with an assembly written one
This commit is contained in:
parent
dfd26b4b8c
commit
5d739383aa
9 changed files with 103 additions and 73 deletions
16
src/input.h
16
src/input.h
|
|
@ -3,16 +3,14 @@
|
|||
|
||||
#include <stdint.h>
|
||||
|
||||
typedef enum {
|
||||
K_NONE = 0,
|
||||
K_UP,
|
||||
K_DOWN,
|
||||
K_LEFT,
|
||||
K_RIGHT,
|
||||
K_CTRL_R,
|
||||
} key;
|
||||
#define K_NONE 0
|
||||
#define K_UP 1
|
||||
#define K_DOWN 2
|
||||
#define K_LEFT 3
|
||||
#define K_RIGHT 4
|
||||
#define K_CTRL_R 5
|
||||
|
||||
key read_kb(void);
|
||||
uint8_t read_kb(void);
|
||||
|
||||
uint8_t read_any_key(void);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue