mirror of
https://gitlab.freedesktop.org/libinput/libinput.git
synced 2026-04-21 21:40:38 +02:00
Use enum wl_keyboard_key_state instead of integer
Instead of using a uint32_t for state everywhere (except on the wire, where that's still the call signature), use the new wl_keyboard_key_state enum, and explicit comparisons. Signed-off-by: Daniel Stone <daniel@fooishbar.org>
This commit is contained in:
parent
95b8738f31
commit
5e29a12788
1 changed files with 3 additions and 1 deletions
|
|
@ -86,7 +86,9 @@ evdev_process_key(struct evdev_input_device *device,
|
|||
|
||||
default:
|
||||
notify_key(&device->master->base.seat,
|
||||
time, e->code, e->value);
|
||||
time, e->code,
|
||||
e->value ? WL_KEYBOARD_KEY_STATE_PRESSED :
|
||||
WL_KEYBOARD_KEY_STATE_RELEASED);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue