mirror of https://github.com/mpv-player/mpv
wayland: clear all keys on keyboard_handle_leave
There was no known problem with this, but according to the wayland
spec*, "After this event client must assume that no keys are
pressed...", so go ahead and do that.
*: 72da004b3e/protocol/wayland.xml (L2449)
This commit is contained in:
parent
221a574a50
commit
9d7638a6f2
|
@ -423,6 +423,10 @@ static void keyboard_handle_leave(void *data, struct wl_keyboard *wl_keyboard,
|
|||
{
|
||||
struct vo_wayland_state *wl = data;
|
||||
wl->has_keyboard_input = false;
|
||||
wl->keyboard_code = 0;
|
||||
wl->mpkey = 0;
|
||||
wl->mpmod = 0;
|
||||
mp_input_put_key(wl->vo->input_ctx, MP_INPUT_RELEASE_ALL);
|
||||
guess_focus(wl);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue