mirror of
https://github.com/reactos/reactos.git
synced 2025-08-03 19:55:41 +00:00
[IMM32] Fix and improve Imm32InquireIme
CORE-11700
This commit is contained in:
parent
72c56c2f1f
commit
91e3d06cdb
1 changed files with 7 additions and 2 deletions
|
@ -54,12 +54,15 @@ BOOL APIENTRY Imm32InquireIme(PIMEDPI pImeDpi)
|
||||||
if (NtUserGetThreadState(THREADSTATE_ISWINLOGON2))
|
if (NtUserGetThreadState(THREADSTATE_ISWINLOGON2))
|
||||||
dwSysInfoFlags |= IME_SYSINFO_WINLOGON;
|
dwSysInfoFlags |= IME_SYSINFO_WINLOGON;
|
||||||
|
|
||||||
|
if (GetWin32ClientInfo()->dwTIFlags & TIF_16BIT)
|
||||||
|
dwSysInfoFlags |= IME_SYSINFO_WOW16;
|
||||||
|
|
||||||
if (IS_IME_HKL(pImeDpi->hKL))
|
if (IS_IME_HKL(pImeDpi->hKL))
|
||||||
{
|
{
|
||||||
if (!pImeDpi->ImeInquire(pImeInfo, szUIClass, dwSysInfoFlags))
|
if (!pImeDpi->ImeInquire(pImeInfo, szUIClass, dwSysInfoFlags))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
else if (IS_CICERO_MODE())
|
else if (IS_CICERO_MODE() && !IS_16BIT_MODE())
|
||||||
{
|
{
|
||||||
if (!pImeDpi->CtfImeInquireExW(pImeInfo, szUIClass, dwSysInfoFlags, pImeDpi->hKL))
|
if (!pImeDpi->CtfImeInquireExW(pImeInfo, szUIClass, dwSysInfoFlags, pImeDpi->hKL))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
@ -139,11 +142,13 @@ BOOL APIENTRY Imm32InquireIme(PIMEDPI pImeDpi)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (pImeDpi->uCodePage != GetACP() && pImeDpi->uCodePage)
|
if (pImeDpi->uCodePage != GetACP() && pImeDpi->uCodePage != CP_ACP)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
MultiByteToWideChar(CP_ACP, MB_PRECOMPOSED, (LPSTR)szUIClass, -1,
|
MultiByteToWideChar(CP_ACP, MB_PRECOMPOSED, (LPSTR)szUIClass, -1,
|
||||||
pImeDpi->szUIClass, _countof(pImeDpi->szUIClass));
|
pImeDpi->szUIClass, _countof(pImeDpi->szUIClass));
|
||||||
|
|
||||||
|
pImeDpi->szUIClass[_countof(pImeDpi->szUIClass) - 1] = UNICODE_NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
return GetClassInfoW(pImeDpi->hInst, pImeDpi->szUIClass, &wcW);
|
return GetClassInfoW(pImeDpi->hInst, pImeDpi->szUIClass, &wcW);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue