From: Ziia Shi <mkrsym1@gmail.com> --- dlls/win32u/driver.c | 12 ++++++++++++ dlls/win32u/sysparams.c | 3 +++ include/ntuser.h | 1 + include/wine/gdi_driver.h | 3 ++- 4 files changed, 18 insertions(+), 1 deletion(-) diff --git a/dlls/win32u/driver.c b/dlls/win32u/driver.c index 60aba702d1a..42f4a11175d 100644 --- a/dlls/win32u/driver.c +++ b/dlls/win32u/driver.c @@ -685,6 +685,11 @@ static BOOL nulldrv_SetIMECompositionRect( HWND hwnd, RECT rect ) return FALSE; } +static BOOL nulldrv_SetIMEEnabled( HWND hwnd, BOOL enabled ) +{ + return FALSE; +} + static LRESULT nulldrv_DesktopWindowProc( HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam ) { return default_window_proc( hwnd, msg, wparam, lparam, FALSE ); @@ -1113,6 +1118,11 @@ static BOOL loaderdrv_SetIMECompositionRect( HWND hwnd, RECT rect ) return load_driver()->pSetIMECompositionRect( hwnd, rect ); } +static BOOL loaderdrv_SetIMEEnabled( HWND hwnd, BOOL enabled ) +{ + return load_driver()->pSetIMEEnabled( hwnd, enabled ); +} + static LONG loaderdrv_ChangeDisplaySettings( LPDEVMODEW displays, LPCWSTR primary_name, HWND hwnd, DWORD flags, LPVOID lparam ) { @@ -1258,6 +1268,7 @@ static const struct user_driver_funcs lazy_load_driver = loaderdrv_ImeProcessKey, loaderdrv_NotifyIMEStatus, loaderdrv_SetIMECompositionRect, + loaderdrv_SetIMEEnabled, /* cursor/icon functions */ nulldrv_DestroyCursorIcon, loaderdrv_SetCursor, @@ -1362,6 +1373,7 @@ void __wine_set_user_driver( const struct user_driver_funcs *funcs, UINT version SET_USER_FUNC(ImeProcessKey); SET_USER_FUNC(NotifyIMEStatus); SET_USER_FUNC(SetIMECompositionRect); + SET_USER_FUNC(SetIMEEnabled); SET_USER_FUNC(DestroyCursorIcon); SET_USER_FUNC(SetCursor); SET_USER_FUNC(GetCursorPos); diff --git a/dlls/win32u/sysparams.c b/dlls/win32u/sysparams.c index 945b03c0b15..d8a144f10bb 100644 --- a/dlls/win32u/sysparams.c +++ b/dlls/win32u/sysparams.c @@ -7607,6 +7607,9 @@ ULONG_PTR WINAPI NtUserCallTwoParam( ULONG_PTR arg1, ULONG_PTR arg2, ULONG code case NtUserCallTwoParam_SetIMECompositionRect: return set_ime_composition_rect( UlongToHandle(arg1), *(const RECT *)arg2 ); + case NtUserCallTwoParam_SetIMEEnabled: + return user_driver->pSetIMEEnabled( UlongToHandle(arg1), arg2 ); + case NtUserCallTwoParam_AdjustWindowRect: { struct adjust_window_rect_params *params = (void *)arg2; diff --git a/include/ntuser.h b/include/ntuser.h index ce1b18fdfd9..84caec08efb 100644 --- a/include/ntuser.h +++ b/include/ntuser.h @@ -1217,6 +1217,7 @@ enum NtUserCallTwoParam_MonitorFromRect, NtUserCallTwoParam_SetIconParam, NtUserCallTwoParam_SetIMECompositionRect, + NtUserCallTwoParam_SetIMEEnabled, NtUserCallTwoParam_AdjustWindowRect, NtUserCallTwoParam_GetVirtualScreenRect, /* temporary exports */ diff --git a/include/wine/gdi_driver.h b/include/wine/gdi_driver.h index f6390bce878..07e8d160691 100644 --- a/include/wine/gdi_driver.h +++ b/include/wine/gdi_driver.h @@ -218,7 +218,7 @@ struct gdi_dc_funcs }; /* increment this when you change the DC function table */ -#define WINE_GDI_DRIVER_VERSION 108 +#define WINE_GDI_DRIVER_VERSION 109 #define GDI_PRIORITY_NULL_DRV 0 /* null driver */ #define GDI_PRIORITY_FONT_DRV 100 /* any font driver */ @@ -375,6 +375,7 @@ struct user_driver_funcs UINT (*pImeProcessKey)(HIMC,UINT,UINT,const BYTE*); void (*pNotifyIMEStatus)(HWND,UINT); BOOL (*pSetIMECompositionRect)(HWND,RECT); + BOOL (*pSetIMEEnabled)(HWND,BOOL); /* cursor/icon functions */ void (*pDestroyCursorIcon)(HCURSOR); void (*pSetCursor)(HWND,HCURSOR); -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/10007