When ImmAssociateContext(hwnd, 0) is called, imm should be disabled. On Debian using uim or fcitx for korean, a program cannot receive KeyPress(VK_HANGUL) because the input method consumes the key. We should change input context to disable it in ImmAssociateContext.
Signed-off-by: Dongwan Kim kdw6485@gmail.com --- dlls/imm32/imm.c | 8 ++++++++ 1 file changed, 8 insertions(+)
diff --git a/dlls/imm32/imm.c b/dlls/imm32/imm.c index 9d2a09f22be..bf243832168 100644 --- a/dlls/imm32/imm.c +++ b/dlls/imm32/imm.c @@ -111,6 +111,7 @@ static CRITICAL_SECTION_DEBUG critsect_debug = }; static CRITICAL_SECTION threaddata_cs = { &critsect_debug, -1, 0, 0, 0, 0 }; static BOOL disable_ime; +static HIMC ( *wine_associate_input_context)(HWND, HIMC);
static inline BOOL is_himc_ime_unicode(const InputContextData *data) { @@ -598,6 +599,13 @@ HIMC WINAPI ImmAssociateContext(HWND hWnd, HIMC hIMC) } }
+ if(!wine_associate_input_context){ + HMODULE h = load_graphics_driver(); + wine_associate_input_context = (LPVOID)GetProcAddress(h, "wine_associate_input_context"); + FreeLibrary(h); + } + if(wine_associate_input_context) + wine_associate_input_context(hWnd, hIMC); if (!hIMC) return old;