server: Fix repeated key for no reason

This commit is contained in:
yuri_k7 2024-08-03 22:01:28 +02:00 committed by YuriK7
parent 01ff2f4a27
commit 4c68b232fb

View file

@ -2433,11 +2433,10 @@ static int queue_keyboard_message( struct desktop *desktop, user_handle_t win, c
}
}
if (origin == IMO_HARDWARE)
if ((origin == IMO_HARDWARE) && (input->kbd.scan == desktop->key_repeat.input.kbd.scan))
{
/* if the repeat key is released, stop auto-repeating */
if (((input->kbd.flags & KEYEVENTF_KEYUP) &&
(input->kbd.scan == desktop->key_repeat.input.kbd.scan)))
if (input->kbd.flags & KEYEVENTF_KEYUP)
{
stop_key_repeat( desktop );
}