[IMM32] GetKeyboardLayout's parameter is a thread id

s/dwLayout/dwThreadId/
CORE-11700
This commit is contained in:
Katayama Hirofumi MZ 2021-10-01 03:13:52 +09:00
parent e6a51b54c4
commit f5bbd57d73

View file

@ -147,17 +147,17 @@ BOOL APIENTRY
Imm32NotifyAction(HIMC hIMC, HWND hwnd, DWORD dwAction, DWORD_PTR dwIndex, DWORD_PTR dwValue, Imm32NotifyAction(HIMC hIMC, HWND hwnd, DWORD dwAction, DWORD_PTR dwIndex, DWORD_PTR dwValue,
DWORD_PTR dwCommand, DWORD_PTR dwData) DWORD_PTR dwCommand, DWORD_PTR dwData)
{ {
DWORD dwLayout; DWORD dwThreadId;
HKL hKL; HKL hKL;
PIMEDPI pImeDpi; PIMEDPI pImeDpi;
if (dwAction) if (dwAction)
{ {
dwLayout = NtUserQueryInputContext(hIMC, 1); dwThreadId = NtUserQueryInputContext(hIMC, 1);
if (dwLayout) if (dwThreadId)
{ {
/* find keyboard layout and lock it */ /* find keyboard layout and lock it */
hKL = GetKeyboardLayout(dwLayout); hKL = GetKeyboardLayout(dwThreadId);
pImeDpi = ImmLockImeDpi(hKL); pImeDpi = ImmLockImeDpi(hKL);
if (pImeDpi) if (pImeDpi)
{ {