mirror of
https://github.com/reactos/reactos.git
synced 2024-11-23 19:43:31 +08:00
[IMM32] Fix and improve Imm32InquireIme
CORE-11700
This commit is contained in:
parent
72c56c2f1f
commit
91e3d06cdb
@ -54,12 +54,15 @@ BOOL APIENTRY Imm32InquireIme(PIMEDPI pImeDpi)
|
||||
if (NtUserGetThreadState(THREADSTATE_ISWINLOGON2))
|
||||
dwSysInfoFlags |= IME_SYSINFO_WINLOGON;
|
||||
|
||||
if (GetWin32ClientInfo()->dwTIFlags & TIF_16BIT)
|
||||
dwSysInfoFlags |= IME_SYSINFO_WOW16;
|
||||
|
||||
if (IS_IME_HKL(pImeDpi->hKL))
|
||||
{
|
||||
if (!pImeDpi->ImeInquire(pImeInfo, szUIClass, dwSysInfoFlags))
|
||||
return FALSE;
|
||||
}
|
||||
else if (IS_CICERO_MODE())
|
||||
else if (IS_CICERO_MODE() && !IS_16BIT_MODE())
|
||||
{
|
||||
if (!pImeDpi->CtfImeInquireExW(pImeInfo, szUIClass, dwSysInfoFlags, pImeDpi->hKL))
|
||||
return FALSE;
|
||||
@ -139,11 +142,13 @@ BOOL APIENTRY Imm32InquireIme(PIMEDPI pImeDpi)
|
||||
}
|
||||
else
|
||||
{
|
||||
if (pImeDpi->uCodePage != GetACP() && pImeDpi->uCodePage)
|
||||
if (pImeDpi->uCodePage != GetACP() && pImeDpi->uCodePage != CP_ACP)
|
||||
return FALSE;
|
||||
|
||||
MultiByteToWideChar(CP_ACP, MB_PRECOMPOSED, (LPSTR)szUIClass, -1,
|
||||
pImeDpi->szUIClass, _countof(pImeDpi->szUIClass));
|
||||
|
||||
pImeDpi->szUIClass[_countof(pImeDpi->szUIClass) - 1] = UNICODE_NULL;
|
||||
}
|
||||
|
||||
return GetClassInfoW(pImeDpi->hInst, pImeDpi->szUIClass, &wcW);
|
||||
|
Loading…
Reference in New Issue
Block a user