1
0
mirror of https://github.com/wine-mirror/wine synced 2024-07-08 20:06:18 +00:00

imm32: Exit early in ImmTranslateMessage when there was no new input.

Signed-off-by: Piotr Caban <piotr@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Piotr Caban 2020-09-25 18:44:56 +02:00 committed by Alexandre Julliard
parent ef12437b69
commit c9988c885d
2 changed files with 3 additions and 1 deletions

View File

@ -3045,7 +3045,7 @@ BOOL WINAPI ImmTranslateMessage(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lKeyD
else
return FALSE;
if (!data->immKbd->hIME || !data->immKbd->pImeToAsciiEx)
if (!data->immKbd->hIME || !data->immKbd->pImeToAsciiEx || data->lastVK == VK_PROCESSKEY)
return FALSE;
GetKeyboardState(state);

View File

@ -1643,6 +1643,8 @@ static void test_ime_processkey(void)
trace("ProcessKey was correctly found\n");
}
TranslateMessage(&msg);
/* test calling TranslateMessage multiple times */
TranslateMessage(&msg);
DispatchMessageW(&msg);
}