diff options
Diffstat (limited to 'sway/input_state.c')
-rw-r--r-- | sway/input_state.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/sway/input_state.c b/sway/input_state.c index e592cfc1..ef5d6df0 100644 --- a/sway/input_state.c +++ b/sway/input_state.c | |||
@@ -8,6 +8,13 @@ | |||
8 | 8 | ||
9 | static keycode key_state_array[KEY_STATE_MAX_LENGTH]; | 9 | static keycode key_state_array[KEY_STATE_MAX_LENGTH]; |
10 | 10 | ||
11 | void input_init(void) { | ||
12 | int i; | ||
13 | for (i = 0; i < KEY_STATE_MAX_LENGTH; ++i) { | ||
14 | key_state_array[i] = 0; | ||
15 | } | ||
16 | } | ||
17 | |||
11 | static uint8_t find_key(keycode key) { | 18 | static uint8_t find_key(keycode key) { |
12 | int i; | 19 | int i; |
13 | for (i = 0; i < KEY_STATE_MAX_LENGTH; ++i) { | 20 | for (i = 0; i < KEY_STATE_MAX_LENGTH; ++i) { |