[IMM32][NTUSER] Add ImmGetImeInfoEx (#3035)

- Add the definition of imm32!ImmGetImeInfoEx function.
- Add IMEINFOEXCLASS and IS_IME_HKL into "ntuser.h".
- Modify NtUserGetImeInfoEx function prototype.
CORE-11700
This commit is contained in:
Katayama Hirofumi MZ 2020-08-12 06:03:29 +09:00 committed by GitHub
parent 047da7e632
commit 4b038ec8b7
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 41 additions and 6 deletions

View file

@ -3242,4 +3242,31 @@ BOOL WINAPI ImmRegisterClient(PVOID ptr, /* FIXME: should point to SHAREDINFO st
FIXME("Stub\n");
return TRUE;
}
/***********************************************************************
* ImmGetImeInfoEx (IMM32.@)
*/
BOOL WINAPI
ImmGetImeInfoEx(PIMEINFOEX pImeInfoEx,
IMEINFOEXCLASS SearchType,
PVOID pvSearchKey)
{
switch (SearchType)
{
case ImeInfoExKeyboardLayout:
pImeInfoEx->hkl = *(LPHKL)pvSearchKey;
if (!IS_IME_HKL(pImeInfoEx->hkl))
return FALSE;
break;
case ImeInfoExImeFileName:
lstrcpynW(pImeInfoEx->wszImeFile, (LPWSTR)pvSearchKey,
ARRAY_SIZE(pImeInfoEx->wszImeFile));
break;
default:
return FALSE;
}
return NtUserGetImeInfoEx(pImeInfoEx, SearchType);
}
#endif

View file

@ -46,7 +46,7 @@
@ stdcall ImmGetIMCLockCount(long)
@ stdcall ImmGetIMEFileNameA(long ptr long)
@ stdcall ImmGetIMEFileNameW(long ptr long)
@ stub ImmGetImeInfoEx
@ stdcall ImmGetImeInfoEx(ptr long ptr)
@ stdcall ImmGetImeMenuItemsA(long long long ptr ptr long)
@ stdcall ImmGetImeMenuItemsW(long long long ptr ptr long)
@ stdcall ImmGetOpenStatus(long)

View file

@ -1174,6 +1174,14 @@ typedef struct tagIMEINFOEX
};
} IMEINFOEX, *PIMEINFOEX;
typedef enum IMEINFOEXCLASS
{
ImeInfoExKeyboardLayout,
ImeInfoExImeFileName
} IMEINFOEXCLASS;
#define IS_IME_HKL(hkl) ((((ULONG_PTR)(hkl)) & 0xF0000000) == 0xE0000000)
typedef struct tagIMEUI
{
PWND spwnd;
@ -2284,11 +2292,11 @@ NtUserGetImeHotKey(IN DWORD dwHotKey,
OUT LPUINT lpuVKey,
OUT LPHKL lphKL);
DWORD
BOOL
NTAPI
NtUserGetImeInfoEx(
PIMEINFOEX pImeInfoEx,
DWORD dwUnknown2);
IMEINFOEXCLASS SearchType);
DWORD
NTAPI

View file

@ -103,14 +103,14 @@ NtUserGetAppImeLevel(
return 0;
}
DWORD
BOOL
APIENTRY
NtUserGetImeInfoEx(
PIMEINFOEX pImeInfoEx,
DWORD dwUnknown2)
IMEINFOEXCLASS SearchType)
{
STUB;
return 0;
return FALSE;
}