From: Jacek Caban jacek@codeweavers.com
--- dlls/win32u/driver.c | 13 +++++++++++++ dlls/win32u/message.c | 3 +++ dlls/wow64win/user.c | 3 +++ include/ntuser.h | 10 ++++++++++ include/wine/gdi_driver.h | 4 +++- 5 files changed, 32 insertions(+), 1 deletion(-)
diff --git a/dlls/win32u/driver.c b/dlls/win32u/driver.c index 75d45a708b1..a13882bd139 100644 --- a/dlls/win32u/driver.c +++ b/dlls/win32u/driver.c @@ -900,6 +900,11 @@ static BOOL nulldrv_SystemParametersInfo( UINT action, UINT int_param, void *ptr return FALSE; }
+static LRESULT nulldrv_WintabProc( HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam, void *buffer ) +{ + return 0; +} + static UINT nulldrv_VulkanInit( UINT version, void *vulkan_handle, const struct vulkan_driver_funcs **driver_funcs ) { return STATUS_NOT_IMPLEMENTED; @@ -1220,6 +1225,11 @@ static void loaderdrv_UpdateLayeredWindow( HWND hwnd, BYTE alpha, UINT flags ) load_driver()->pUpdateLayeredWindow( hwnd, alpha, flags ); }
+static LRESULT loaderdrv_WintabProc( HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam, void *buffer ) +{ + return load_driver()->pWintabProc( hwnd, msg, wparam, lparam, buffer ); +} + static UINT loaderdrv_VulkanInit( UINT version, void *vulkan_handle, const struct vulkan_driver_funcs **driver_funcs ) { return load_driver()->pVulkanInit( version, vulkan_handle, driver_funcs ); @@ -1293,6 +1303,8 @@ static const struct user_driver_funcs lazy_load_driver = nulldrv_WindowPosChanged, /* system parameters */ nulldrv_SystemParametersInfo, + /* wintab support */ + loaderdrv_WintabProc, /* vulkan support */ loaderdrv_VulkanInit, /* opengl support */ @@ -1389,6 +1401,7 @@ void __wine_set_user_driver( const struct user_driver_funcs *funcs, UINT version SET_USER_FUNC(MoveWindowBits); SET_USER_FUNC(WindowPosChanged); SET_USER_FUNC(SystemParametersInfo); + SET_USER_FUNC(WintabProc); SET_USER_FUNC(VulkanInit); SET_USER_FUNC(OpenGLInit); SET_USER_FUNC(ThreadDetach); diff --git a/dlls/win32u/message.c b/dlls/win32u/message.c index 6a5c257d878..e2535fed6d6 100644 --- a/dlls/win32u/message.c +++ b/dlls/win32u/message.c @@ -4707,6 +4707,9 @@ LRESULT WINAPI NtUserMessageCall( HWND hwnd, UINT msg, WPARAM wparam, LPARAM lpa case NtUserPostDdeCall: return post_dde_message_call( hwnd, msg, wparam, lparam, result_info );
+ case NtUserWintabDriverCall: + return user_driver->pWintabProc( hwnd, msg, wparam, lparam, result_info ); + default: FIXME( "%p %x %lx %lx %p %x %x\n", hwnd, msg, (long)wparam, lparam, result_info, type, ansi ); } diff --git a/dlls/wow64win/user.c b/dlls/wow64win/user.c index 66df9d04d54..d4f47773abe 100644 --- a/dlls/wow64win/user.c +++ b/dlls/wow64win/user.c @@ -3799,6 +3799,9 @@ NTSTATUS WINAPI wow64_NtUserMessageCall( UINT *args ) params.dest_tid = params32->dest_tid; return NtUserMessageCall( hwnd, msg, wparam, lparam, ¶ms, type, ansi ); } + + case NtUserWintabDriverCall: + return NtUserMessageCall( hwnd, msg, wparam, lparam, result_info, type, ansi ); }
return message_call_32to64( hwnd, msg, wparam, lparam, result_info, type, ansi ); diff --git a/include/ntuser.h b/include/ntuser.h index 556b8bbbf51..664bcfe459d 100644 --- a/include/ntuser.h +++ b/include/ntuser.h @@ -422,6 +422,16 @@ enum NtUserSystemTrayCall = 0x0306, NtUserDragDropCall = 0x0307, NtUserPostDdeCall = 0x0308, + NtUserWintabDriverCall = 0x0309, +}; + +/* NtUserWintabDriverCall codes */ +enum +{ + NtUserWintabAttach, + NtUserWintabInfo, + NtUserWintabInit, + NtUserWintabPacket, };
/* NtUserThunkedMenuItemInfo codes */ diff --git a/include/wine/gdi_driver.h b/include/wine/gdi_driver.h index cdc838d36d8..ff903f4a51d 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 107 +#define WINE_GDI_DRIVER_VERSION 108
#define GDI_PRIORITY_NULL_DRV 0 /* null driver */ #define GDI_PRIORITY_FONT_DRV 100 /* any font driver */ @@ -427,6 +427,8 @@ struct user_driver_funcs void (*pWindowPosChanged)(HWND,HWND,HWND,UINT,BOOL,const struct window_rects*,struct window_surface*); /* system parameters */ BOOL (*pSystemParametersInfo)(UINT,UINT,void*,UINT); + /* wintab support */ + LRESULT (*pWintabProc)(HWND,UINT,WPARAM,LPARAM,void*); /* vulkan support */ UINT (*pVulkanInit)(UINT,void *,const struct vulkan_driver_funcs **); /* opengl support */
From: Jacek Caban jacek@codeweavers.com
--- dlls/winex11.drv/dllmain.c | 8 -------- dlls/winex11.drv/init.c | 1 + dlls/winex11.drv/unixlib.h | 1 - dlls/winex11.drv/winex11.drv.spec | 1 - dlls/winex11.drv/wintab.c | 25 +++++++++++++++++++------ dlls/winex11.drv/x11drv.h | 2 +- dlls/winex11.drv/x11drv_main.c | 2 -- dlls/wintab32/Makefile.in | 2 +- dlls/wintab32/context.c | 4 ++-- dlls/wintab32/wintab32.c | 2 -- dlls/wintab32/wintab_internal.h | 1 - 11 files changed, 24 insertions(+), 25 deletions(-)
diff --git a/dlls/winex11.drv/dllmain.c b/dlls/winex11.drv/dllmain.c index c4f80895a65..b2c3b75065c 100644 --- a/dlls/winex11.drv/dllmain.c +++ b/dlls/winex11.drv/dllmain.c @@ -36,14 +36,6 @@ BOOL WINAPI DllMain( HINSTANCE instance, DWORD reason, void *reserved ) return TRUE; }
-/*********************************************************************** - * AttachEventQueueToTablet (winex11.@) - */ -int CDECL X11DRV_AttachEventQueueToTablet( HWND owner ) -{ - return X11DRV_CALL( tablet_attach_queue, owner ); -} - /*********************************************************************** * GetCurrentPacket (winex11.@) */ diff --git a/dlls/winex11.drv/init.c b/dlls/winex11.drv/init.c index e7a56252e4e..057ea529772 100644 --- a/dlls/winex11.drv/init.c +++ b/dlls/winex11.drv/init.c @@ -671,6 +671,7 @@ static const struct user_driver_funcs x11drv_funcs = .pMoveWindowBits = X11DRV_MoveWindowBits, .pWindowPosChanged = X11DRV_WindowPosChanged, .pSystemParametersInfo = X11DRV_SystemParametersInfo, + .pWintabProc = X11DRV_WintabProc, .pVulkanInit = X11DRV_VulkanInit, .pOpenGLInit = X11DRV_OpenGLInit, .pThreadDetach = X11DRV_ThreadDetach, diff --git a/dlls/winex11.drv/unixlib.h b/dlls/winex11.drv/unixlib.h index e2b1cb9704f..07da331d656 100644 --- a/dlls/winex11.drv/unixlib.h +++ b/dlls/winex11.drv/unixlib.h @@ -23,7 +23,6 @@ enum x11drv_funcs { unix_init, - unix_tablet_attach_queue, unix_tablet_get_packet, unix_tablet_info, unix_tablet_load_info, diff --git a/dlls/winex11.drv/winex11.drv.spec b/dlls/winex11.drv/winex11.drv.spec index 43d9ae6ba71..3bd451597bf 100644 --- a/dlls/winex11.drv/winex11.drv.spec +++ b/dlls/winex11.drv/winex11.drv.spec @@ -1,5 +1,4 @@ # WinTab32 -@ cdecl AttachEventQueueToTablet(long) X11DRV_AttachEventQueueToTablet @ cdecl GetCurrentPacket(ptr) X11DRV_GetCurrentPacket @ cdecl LoadTabletInfo(long) X11DRV_LoadTabletInfo @ cdecl WTInfoW(long long ptr) X11DRV_WTInfoW diff --git a/dlls/winex11.drv/wintab.c b/dlls/winex11.drv/wintab.c index a817ce4eff2..2905b37d2cc 100644 --- a/dlls/winex11.drv/wintab.c +++ b/dlls/winex11.drv/wintab.c @@ -1003,9 +1003,9 @@ static BOOL proximity_event( HWND hwnd, XEvent *event ) }
/*********************************************************************** - * x11drv_tablet_attach_queue + * tablet_attach_queue */ -NTSTATUS x11drv_tablet_attach_queue( void *owner ) +static BOOL tablet_attach_queue( HWND owner ) { struct x11drv_thread_data *data = x11drv_init_thread_data(); int num_devices; @@ -1017,7 +1017,7 @@ NTSTATUS x11drv_tablet_attach_queue( void *owner ) XEventClass event_list[7]; Window win = X11DRV_get_whole_window( owner );
- if (!win || !xinput_handle) return 0; + if (!win || !xinput_handle) return FALSE;
TRACE("Creating context for window %p (%lx) %i cursors\n", owner, win, gNumCursors);
@@ -1091,7 +1091,7 @@ NTSTATUS x11drv_tablet_attach_queue( void *owner ) X11DRV_check_error();
if (NULL != devices) pXFreeDeviceList(devices); - return 0; + return TRUE; }
/*********************************************************************** @@ -1550,12 +1550,25 @@ NTSTATUS x11drv_tablet_info( void *arg ) return rc; }
+/*********************************************************************** + * X11DRV_WintabProc + */ +LRESULT X11DRV_WintabProc( HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam, void *buffer ) +{ + switch (msg) + { + case NtUserWintabAttach: + return tablet_attach_queue( hwnd ); + } + return 0; +} + #else /* SONAME_LIBXI */
/*********************************************************************** - * x11drv_tablet_attach_queue + * X11DRV_WintabProc */ -NTSTATUS x11drv_tablet_attach_queue( void *owner ) +LRESULT X11DRV_WintabProc( HWND hwmd, UINT msg, WPARAM wparam, LPARAM lparam, void *buffer ) { return 0; } diff --git a/dlls/winex11.drv/x11drv.h b/dlls/winex11.drv/x11drv.h index 63d6a316642..0d2823651a4 100644 --- a/dlls/winex11.drv/x11drv.h +++ b/dlls/winex11.drv/x11drv.h @@ -251,6 +251,7 @@ extern void X11DRV_WindowPosChanged( HWND hwnd, HWND insert_after, HWND owner_hi const struct window_rects *new_rects, struct window_surface *surface ); extern BOOL X11DRV_SystemParametersInfo( UINT action, UINT int_param, void *ptr_param, UINT flags ); +extern LRESULT X11DRV_WintabProc( HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam, void *buffer ); extern void X11DRV_ThreadDetach(void);
/* X11 driver internal functions */ @@ -897,7 +898,6 @@ static inline BOOL is_window_rect_mapped( const RECT *rect )
/* unixlib interface */
-extern NTSTATUS x11drv_tablet_attach_queue( void *arg ); extern NTSTATUS x11drv_tablet_get_packet( void *arg ); extern NTSTATUS x11drv_tablet_load_info( void *arg ); extern NTSTATUS x11drv_tablet_info( void *arg ); diff --git a/dlls/winex11.drv/x11drv_main.c b/dlls/winex11.drv/x11drv_main.c index e078a66fbb0..bf9064970de 100644 --- a/dlls/winex11.drv/x11drv_main.c +++ b/dlls/winex11.drv/x11drv_main.c @@ -806,7 +806,6 @@ BOOL X11DRV_SystemParametersInfo( UINT action, UINT int_param, void *ptr_param, const unixlib_entry_t __wine_unix_call_funcs[] = { x11drv_init, - x11drv_tablet_attach_queue, x11drv_tablet_get_packet, x11drv_tablet_info, x11drv_tablet_load_info, @@ -837,7 +836,6 @@ static NTSTATUS x11drv_wow64_tablet_info( void *arg ) const unixlib_entry_t __wine_unix_call_wow64_funcs[] = { x11drv_init, - x11drv_tablet_attach_queue, x11drv_tablet_get_packet, x11drv_wow64_tablet_info, x11drv_tablet_load_info, diff --git a/dlls/wintab32/Makefile.in b/dlls/wintab32/Makefile.in index 52e9312af6f..b67e91a7e20 100644 --- a/dlls/wintab32/Makefile.in +++ b/dlls/wintab32/Makefile.in @@ -1,6 +1,6 @@ MODULE = wintab32.dll IMPORTLIB = wintab32 -IMPORTS = user32 advapi32 +IMPORTS = user32 advapi32 win32u
SOURCES = \ context.c \ diff --git a/dlls/wintab32/context.c b/dlls/wintab32/context.c index bd0c982da2d..510c268b72e 100644 --- a/dlls/wintab32/context.c +++ b/dlls/wintab32/context.c @@ -26,7 +26,7 @@ #include "windef.h" #include "winerror.h" #include "winbase.h" -#include "winuser.h" +#include "ntuser.h" #include "winnls.h"
#include "wintab.h" @@ -481,7 +481,7 @@ HCTX WINAPI WTOpenW(HWND hWnd, LPLOGCONTEXTW lpLogCtx, BOOL fEnable) gOpenContexts = newcontext; LeaveCriticalSection(&csTablet);
- pAttachEventQueueToTablet(hWnd); + NtUserMessageCall(hWnd, NtUserWintabAttach, 0, 0, NULL, NtUserWintabDriverCall, FALSE);
TABLET_PostTabletMessage(newcontext, _WT_CTXOPEN(newcontext->context.lcMsgBase), (WPARAM)newcontext->handle, newcontext->context.lcStatus, TRUE); diff --git a/dlls/wintab32/wintab32.c b/dlls/wintab32/wintab32.c index b13c0573454..415a4dbca0f 100644 --- a/dlls/wintab32/wintab32.c +++ b/dlls/wintab32/wintab32.c @@ -44,7 +44,6 @@ CRITICAL_SECTION csTablet = { &csTablet_debug, -1, 0, 0, 0, 0 };
int (CDECL *pLoadTabletInfo)(HWND hwnddefault) = NULL; int (CDECL *pGetCurrentPacket)(LPWTPACKET packet) = NULL; -int (CDECL *pAttachEventQueueToTablet)(HWND hOwner) = NULL; UINT (CDECL *pWTInfoW)(UINT wCategory, UINT nIndex, LPVOID lpOutput) = NULL;
static LRESULT WINAPI TABLET_WindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, @@ -108,7 +107,6 @@ BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD fdwReason, LPVOID lpReserved) { HMODULE module = load_graphics_driver(); pLoadTabletInfo = (void *)GetProcAddress(module, "LoadTabletInfo"); - pAttachEventQueueToTablet = (void *)GetProcAddress(module, "AttachEventQueueToTablet"); pGetCurrentPacket = (void *)GetProcAddress(module, "GetCurrentPacket"); pWTInfoW = (void *)GetProcAddress(module, "WTInfoW"); } diff --git a/dlls/wintab32/wintab_internal.h b/dlls/wintab32/wintab_internal.h index f1529a59bb1..049c54f8cdb 100644 --- a/dlls/wintab32/wintab_internal.h +++ b/dlls/wintab32/wintab_internal.h @@ -153,7 +153,6 @@ LPOPENCONTEXT AddPacketToContextQueue(LPWTPACKET packet, HWND hwnd); /* X11drv functions */ extern int (CDECL *pLoadTabletInfo)(HWND hwnddefault); extern int (CDECL *pGetCurrentPacket)(LPWTPACKET packet); -extern int (CDECL *pAttachEventQueueToTablet)(HWND hOwner); extern UINT (CDECL *pWTInfoW)(UINT wCategory, UINT nIndex, LPVOID lpOutput);
extern HWND hwndDefault;
From: Jacek Caban jacek@codeweavers.com
--- dlls/winex11.drv/dllmain.c | 8 -------- dlls/winex11.drv/unixlib.h | 1 - dlls/winex11.drv/winex11.drv.spec | 1 - dlls/winex11.drv/wintab.c | 21 +++------------------ dlls/winex11.drv/x11drv.h | 1 - dlls/winex11.drv/x11drv_main.c | 2 -- dlls/wintab32/wintab32.c | 10 +++------- dlls/wintab32/wintab_internal.h | 1 - 8 files changed, 6 insertions(+), 39 deletions(-)
diff --git a/dlls/winex11.drv/dllmain.c b/dlls/winex11.drv/dllmain.c index b2c3b75065c..265d3d8368c 100644 --- a/dlls/winex11.drv/dllmain.c +++ b/dlls/winex11.drv/dllmain.c @@ -36,14 +36,6 @@ BOOL WINAPI DllMain( HINSTANCE instance, DWORD reason, void *reserved ) return TRUE; }
-/*********************************************************************** - * GetCurrentPacket (winex11.@) - */ -int CDECL X11DRV_GetCurrentPacket( void *packet ) -{ - return X11DRV_CALL( tablet_get_packet, packet ); -} - /*********************************************************************** * LoadTabletInfo (winex11.@) */ diff --git a/dlls/winex11.drv/unixlib.h b/dlls/winex11.drv/unixlib.h index 07da331d656..ca55ae25a0d 100644 --- a/dlls/winex11.drv/unixlib.h +++ b/dlls/winex11.drv/unixlib.h @@ -23,7 +23,6 @@ enum x11drv_funcs { unix_init, - unix_tablet_get_packet, unix_tablet_info, unix_tablet_load_info, unix_funcs_count, diff --git a/dlls/winex11.drv/winex11.drv.spec b/dlls/winex11.drv/winex11.drv.spec index 3bd451597bf..3127508edd9 100644 --- a/dlls/winex11.drv/winex11.drv.spec +++ b/dlls/winex11.drv/winex11.drv.spec @@ -1,4 +1,3 @@ # WinTab32 -@ cdecl GetCurrentPacket(ptr) X11DRV_GetCurrentPacket @ cdecl LoadTabletInfo(long) X11DRV_LoadTabletInfo @ cdecl WTInfoW(long long ptr) X11DRV_WTInfoW diff --git a/dlls/winex11.drv/wintab.c b/dlls/winex11.drv/wintab.c index 2905b37d2cc..7e3ce180854 100644 --- a/dlls/winex11.drv/wintab.c +++ b/dlls/winex11.drv/wintab.c @@ -1094,16 +1094,6 @@ static BOOL tablet_attach_queue( HWND owner ) return TRUE; }
-/*********************************************************************** - * x11drv_tablet_get_packet - */ -NTSTATUS x11drv_tablet_get_packet( void *packet ) -{ - *(WTPACKET *)packet = gMsgPacket; - return 1; -} - - static inline int CopyTabletData(LPVOID target, LPCVOID src, INT size) { /* @@ -1559,6 +1549,9 @@ LRESULT X11DRV_WintabProc( HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam, vo { case NtUserWintabAttach: return tablet_attach_queue( hwnd ); + case NtUserWintabPacket: + *(WTPACKET *)buffer = gMsgPacket; + return 1; } return 0; } @@ -1573,14 +1566,6 @@ LRESULT X11DRV_WintabProc( HWND hwmd, UINT msg, WPARAM wparam, LPARAM lparam, vo return 0; }
-/*********************************************************************** - * x11drv_tablet_get_packet - */ -NTSTATUS x11drv_tablet_get_packet( void *arg ) -{ - return 0; -} - /*********************************************************************** * x11drv_tablet_load_info */ diff --git a/dlls/winex11.drv/x11drv.h b/dlls/winex11.drv/x11drv.h index 0d2823651a4..c5599a214c1 100644 --- a/dlls/winex11.drv/x11drv.h +++ b/dlls/winex11.drv/x11drv.h @@ -898,7 +898,6 @@ static inline BOOL is_window_rect_mapped( const RECT *rect )
/* unixlib interface */
-extern NTSTATUS x11drv_tablet_get_packet( void *arg ); extern NTSTATUS x11drv_tablet_load_info( void *arg ); extern NTSTATUS x11drv_tablet_info( void *arg );
diff --git a/dlls/winex11.drv/x11drv_main.c b/dlls/winex11.drv/x11drv_main.c index bf9064970de..4e7439c7f20 100644 --- a/dlls/winex11.drv/x11drv_main.c +++ b/dlls/winex11.drv/x11drv_main.c @@ -806,7 +806,6 @@ BOOL X11DRV_SystemParametersInfo( UINT action, UINT int_param, void *ptr_param, const unixlib_entry_t __wine_unix_call_funcs[] = { x11drv_init, - x11drv_tablet_get_packet, x11drv_tablet_info, x11drv_tablet_load_info, }; @@ -836,7 +835,6 @@ static NTSTATUS x11drv_wow64_tablet_info( void *arg ) const unixlib_entry_t __wine_unix_call_wow64_funcs[] = { x11drv_init, - x11drv_tablet_get_packet, x11drv_wow64_tablet_info, x11drv_tablet_load_info, }; diff --git a/dlls/wintab32/wintab32.c b/dlls/wintab32/wintab32.c index 415a4dbca0f..98a7e47a120 100644 --- a/dlls/wintab32/wintab32.c +++ b/dlls/wintab32/wintab32.c @@ -24,7 +24,7 @@ #include "winbase.h" #include "winreg.h" #include "wingdi.h" -#include "winuser.h" +#include "ntuser.h" #include "winerror.h" #define NOFIX32 #include "wintab.h" @@ -43,7 +43,6 @@ static CRITICAL_SECTION_DEBUG csTablet_debug = CRITICAL_SECTION csTablet = { &csTablet_debug, -1, 0, 0, 0, 0 };
int (CDECL *pLoadTabletInfo)(HWND hwnddefault) = NULL; -int (CDECL *pGetCurrentPacket)(LPWTPACKET packet) = NULL; UINT (CDECL *pWTInfoW)(UINT wCategory, UINT nIndex, LPVOID lpOutput) = NULL;
static LRESULT WINAPI TABLET_WindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, @@ -107,7 +106,6 @@ BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD fdwReason, LPVOID lpReserved) { HMODULE module = load_graphics_driver(); pLoadTabletInfo = (void *)GetProcAddress(module, "LoadTabletInfo"); - pGetCurrentPacket = (void *)GetProcAddress(module, "GetCurrentPacket"); pWTInfoW = (void *)GetProcAddress(module, "WTInfoW"); } else @@ -143,9 +141,8 @@ static LRESULT WINAPI TABLET_WindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, { WTPACKET packet; LPOPENCONTEXT handler; - if (pGetCurrentPacket) + if (NtUserMessageCall(hwnd, NtUserWintabPacket, 0, 0, &packet, NtUserWintabDriverCall, FALSE)) { - pGetCurrentPacket(&packet); handler = AddPacketToContextQueue(&packet,(HWND)lParam); if (handler && handler->context.lcOptions & CXO_MESSAGES) TABLET_PostTabletMessage(handler, _WT_PACKET(handler->context.lcMsgBase), @@ -158,9 +155,8 @@ static LRESULT WINAPI TABLET_WindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, { WTPACKET packet; LPOPENCONTEXT handler; - if (pGetCurrentPacket) + if (NtUserMessageCall(hwnd, NtUserWintabPacket, 0, 0, &packet, NtUserWintabDriverCall, FALSE)) { - pGetCurrentPacket(&packet); handler = AddPacketToContextQueue(&packet,(HWND)wParam); if (handler) TABLET_PostTabletMessage(handler, WT_PROXIMITY, diff --git a/dlls/wintab32/wintab_internal.h b/dlls/wintab32/wintab_internal.h index 049c54f8cdb..26a5c628473 100644 --- a/dlls/wintab32/wintab_internal.h +++ b/dlls/wintab32/wintab_internal.h @@ -152,7 +152,6 @@ LPOPENCONTEXT AddPacketToContextQueue(LPWTPACKET packet, HWND hwnd);
/* X11drv functions */ extern int (CDECL *pLoadTabletInfo)(HWND hwnddefault); -extern int (CDECL *pGetCurrentPacket)(LPWTPACKET packet); extern UINT (CDECL *pWTInfoW)(UINT wCategory, UINT nIndex, LPVOID lpOutput);
extern HWND hwndDefault;
From: Jacek Caban jacek@codeweavers.com
--- dlls/winex11.drv/dllmain.c | 12 ------------ dlls/winex11.drv/unixlib.h | 9 --------- dlls/winex11.drv/winex11.drv.spec | 1 - dlls/winex11.drv/wintab.c | 11 ++++------- dlls/winex11.drv/x11drv.h | 1 - dlls/winex11.drv/x11drv_main.c | 18 ------------------ dlls/wintab32/context.c | 12 ++++++++---- dlls/wintab32/wintab32.c | 2 -- dlls/wintab32/wintab_internal.h | 1 - 9 files changed, 12 insertions(+), 55 deletions(-)
diff --git a/dlls/winex11.drv/dllmain.c b/dlls/winex11.drv/dllmain.c index 265d3d8368c..5fee14d3957 100644 --- a/dlls/winex11.drv/dllmain.c +++ b/dlls/winex11.drv/dllmain.c @@ -43,15 +43,3 @@ BOOL CDECL X11DRV_LoadTabletInfo( HWND hwnd ) { return X11DRV_CALL( tablet_load_info, hwnd ); } - -/*********************************************************************** - * WTInfoW (winex11.@) - */ -UINT CDECL X11DRV_WTInfoW( UINT category, UINT index, void *output ) -{ - struct tablet_info_params params; - params.category = category; - params.index = index; - params.output = output; - return X11DRV_CALL( tablet_info, ¶ms ); -} diff --git a/dlls/winex11.drv/unixlib.h b/dlls/winex11.drv/unixlib.h index ca55ae25a0d..463f06adda6 100644 --- a/dlls/winex11.drv/unixlib.h +++ b/dlls/winex11.drv/unixlib.h @@ -23,17 +23,8 @@ enum x11drv_funcs { unix_init, - unix_tablet_info, unix_tablet_load_info, unix_funcs_count, };
#define X11DRV_CALL(func, params) WINE_UNIX_CALL( unix_ ## func, params ) - -/* x11drv_tablet_info params */ -struct tablet_info_params -{ - UINT category; - UINT index; - void *output; -}; diff --git a/dlls/winex11.drv/winex11.drv.spec b/dlls/winex11.drv/winex11.drv.spec index 3127508edd9..411111bd513 100644 --- a/dlls/winex11.drv/winex11.drv.spec +++ b/dlls/winex11.drv/winex11.drv.spec @@ -1,3 +1,2 @@ # WinTab32 @ cdecl LoadTabletInfo(long) X11DRV_LoadTabletInfo -@ cdecl WTInfoW(long long ptr) X11DRV_WTInfoW diff --git a/dlls/winex11.drv/wintab.c b/dlls/winex11.drv/wintab.c index 7e3ce180854..ee0dd96e540 100644 --- a/dlls/winex11.drv/wintab.c +++ b/dlls/winex11.drv/wintab.c @@ -1106,15 +1106,10 @@ static inline int CopyTabletData(LPVOID target, LPCVOID src, INT size) }
/*********************************************************************** - * x11drv_tablet_info + * get_tablet_info */ -NTSTATUS x11drv_tablet_info( void *arg ) +static UINT get_tablet_info( UINT wCategory, UINT nIndex, void *lpOutput ) { - struct tablet_info_params *params = arg; - UINT wCategory = params->category; - UINT nIndex = params->index; - void *lpOutput = params->output; - /* * It is valid to call WTInfoA with lpOutput == NULL, as per standard. * lpOutput == NULL signifies the user only wishes @@ -1549,6 +1544,8 @@ LRESULT X11DRV_WintabProc( HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam, vo { case NtUserWintabAttach: return tablet_attach_queue( hwnd ); + case NtUserWintabInfo: + return get_tablet_info( wparam, lparam, buffer ); case NtUserWintabPacket: *(WTPACKET *)buffer = gMsgPacket; return 1; diff --git a/dlls/winex11.drv/x11drv.h b/dlls/winex11.drv/x11drv.h index c5599a214c1..b6ea393f480 100644 --- a/dlls/winex11.drv/x11drv.h +++ b/dlls/winex11.drv/x11drv.h @@ -899,7 +899,6 @@ static inline BOOL is_window_rect_mapped( const RECT *rect ) /* unixlib interface */
extern NTSTATUS x11drv_tablet_load_info( void *arg ); -extern NTSTATUS x11drv_tablet_info( void *arg );
/* GDI helpers */
diff --git a/dlls/winex11.drv/x11drv_main.c b/dlls/winex11.drv/x11drv_main.c index 4e7439c7f20..35cb08da5a6 100644 --- a/dlls/winex11.drv/x11drv_main.c +++ b/dlls/winex11.drv/x11drv_main.c @@ -806,7 +806,6 @@ BOOL X11DRV_SystemParametersInfo( UINT action, UINT int_param, void *ptr_param, const unixlib_entry_t __wine_unix_call_funcs[] = { x11drv_init, - x11drv_tablet_info, x11drv_tablet_load_info, };
@@ -816,26 +815,9 @@ C_ASSERT( ARRAYSIZE(__wine_unix_call_funcs) == unix_funcs_count );
#ifdef _WIN64
-static NTSTATUS x11drv_wow64_tablet_info( void *arg ) -{ - struct - { - UINT category; - UINT index; - ULONG output; - } *params32 = arg; - struct tablet_info_params params; - - params.category = params32->category; - params.index = params32->index; - params.output = UlongToPtr( params32->output ); - return x11drv_tablet_info( ¶ms ); -} - const unixlib_entry_t __wine_unix_call_wow64_funcs[] = { x11drv_init, - x11drv_wow64_tablet_info, x11drv_tablet_load_info, };
diff --git a/dlls/wintab32/context.c b/dlls/wintab32/context.c index 510c268b72e..ec243b7b2cc 100644 --- a/dlls/wintab32/context.c +++ b/dlls/wintab32/context.c @@ -373,6 +373,10 @@ static VOID TABLET_BlankPacketData(LPOPENCONTEXT context, LPVOID lpPkt, INT n) memset(lpPkt,0,rc); }
+static UINT DriverInfo(UINT category, UINT index, void *output) +{ + return NtUserMessageCall(NULL, NtUserWintabInfo, category, index, output, NtUserWintabDriverCall, FALSE); +}
static UINT WTInfoT(UINT wCategory, UINT nIndex, LPVOID lpOutput, BOOL bUnicode) { @@ -406,7 +410,7 @@ static UINT WTInfoT(UINT wCategory, UINT nIndex, LPVOID lpOutput, BOOL bUnicode) if (lpOutput) { LOGCONTEXTW buf; - pWTInfoW(wCategory, nIndex, &buf); + DriverInfo(wCategory, nIndex, &buf);
/* Handle system extents here, as we can use user32.dll code to set them */ if(wCategory == WTI_DEFSYSCTX) @@ -425,14 +429,14 @@ static UINT WTInfoT(UINT wCategory, UINT nIndex, LPVOID lpOutput, BOOL bUnicode) } else if (is_string_field(wCategory, nIndex) && !bUnicode) { - int size = pWTInfoW(wCategory, nIndex, NULL); + int size = DriverInfo(wCategory, nIndex, NULL); WCHAR *buf = malloc(size); - pWTInfoW(wCategory, nIndex, buf); + DriverInfo(wCategory, nIndex, buf); result = WideCharToMultiByte(CP_ACP, 0, buf, size/sizeof(WCHAR), lpOutput, lpOutput ? 2*size : 0, NULL, NULL); free(buf); } else - result = pWTInfoW(wCategory, nIndex, lpOutput); + result = DriverInfo(wCategory, nIndex, lpOutput);
TRACE("returns %d\n", result); return result; diff --git a/dlls/wintab32/wintab32.c b/dlls/wintab32/wintab32.c index 98a7e47a120..f9860244cac 100644 --- a/dlls/wintab32/wintab32.c +++ b/dlls/wintab32/wintab32.c @@ -43,7 +43,6 @@ static CRITICAL_SECTION_DEBUG csTablet_debug = CRITICAL_SECTION csTablet = { &csTablet_debug, -1, 0, 0, 0, 0 };
int (CDECL *pLoadTabletInfo)(HWND hwnddefault) = NULL; -UINT (CDECL *pWTInfoW)(UINT wCategory, UINT nIndex, LPVOID lpOutput) = NULL;
static LRESULT WINAPI TABLET_WindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam); @@ -106,7 +105,6 @@ BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD fdwReason, LPVOID lpReserved) { HMODULE module = load_graphics_driver(); pLoadTabletInfo = (void *)GetProcAddress(module, "LoadTabletInfo"); - pWTInfoW = (void *)GetProcAddress(module, "WTInfoW"); } else return FALSE; diff --git a/dlls/wintab32/wintab_internal.h b/dlls/wintab32/wintab_internal.h index 26a5c628473..1c13df74402 100644 --- a/dlls/wintab32/wintab_internal.h +++ b/dlls/wintab32/wintab_internal.h @@ -152,7 +152,6 @@ LPOPENCONTEXT AddPacketToContextQueue(LPWTPACKET packet, HWND hwnd);
/* X11drv functions */ extern int (CDECL *pLoadTabletInfo)(HWND hwnddefault); -extern UINT (CDECL *pWTInfoW)(UINT wCategory, UINT nIndex, LPVOID lpOutput);
extern HWND hwndDefault; extern CRITICAL_SECTION csTablet;
From: Jacek Caban jacek@codeweavers.com
--- dlls/winex11.drv/Makefile.in | 1 - dlls/winex11.drv/dllmain.c | 8 -------- dlls/winex11.drv/unixlib.h | 1 - dlls/winex11.drv/winex11.drv.spec | 2 -- dlls/winex11.drv/wintab.c | 4 +++- dlls/winex11.drv/x11drv.h | 4 ---- dlls/winex11.drv/x11drv_main.c | 2 -- dlls/wintab32/context.c | 2 +- dlls/wintab32/wintab32.c | 33 +------------------------------ dlls/wintab32/wintab_internal.h | 3 --- 10 files changed, 5 insertions(+), 55 deletions(-) delete mode 100644 dlls/winex11.drv/winex11.drv.spec
diff --git a/dlls/winex11.drv/Makefile.in b/dlls/winex11.drv/Makefile.in index a4023babea3..9806dd350e9 100644 --- a/dlls/winex11.drv/Makefile.in +++ b/dlls/winex11.drv/Makefile.in @@ -22,7 +22,6 @@ SOURCES = \ version.rc \ vulkan.c \ window.c \ - winex11.drv.spec \ wintab.c \ x11drv_main.c \ xim.c \ diff --git a/dlls/winex11.drv/dllmain.c b/dlls/winex11.drv/dllmain.c index 5fee14d3957..2e96b920606 100644 --- a/dlls/winex11.drv/dllmain.c +++ b/dlls/winex11.drv/dllmain.c @@ -35,11 +35,3 @@ BOOL WINAPI DllMain( HINSTANCE instance, DWORD reason, void *reserved )
return TRUE; } - -/*********************************************************************** - * LoadTabletInfo (winex11.@) - */ -BOOL CDECL X11DRV_LoadTabletInfo( HWND hwnd ) -{ - return X11DRV_CALL( tablet_load_info, hwnd ); -} diff --git a/dlls/winex11.drv/unixlib.h b/dlls/winex11.drv/unixlib.h index 463f06adda6..5da7abc1bfd 100644 --- a/dlls/winex11.drv/unixlib.h +++ b/dlls/winex11.drv/unixlib.h @@ -23,7 +23,6 @@ enum x11drv_funcs { unix_init, - unix_tablet_load_info, unix_funcs_count, };
diff --git a/dlls/winex11.drv/winex11.drv.spec b/dlls/winex11.drv/winex11.drv.spec deleted file mode 100644 index 411111bd513..00000000000 --- a/dlls/winex11.drv/winex11.drv.spec +++ /dev/null @@ -1,2 +0,0 @@ -# WinTab32 -@ cdecl LoadTabletInfo(long) X11DRV_LoadTabletInfo diff --git a/dlls/winex11.drv/wintab.c b/dlls/winex11.drv/wintab.c index ee0dd96e540..3dfbb5259ef 100644 --- a/dlls/winex11.drv/wintab.c +++ b/dlls/winex11.drv/wintab.c @@ -485,7 +485,7 @@ static void disable_system_cursors(void) /*********************************************************************** * x11drv_tablet_load_info */ -NTSTATUS x11drv_tablet_load_info( void *hwnd ) +static BOOL load_tablet_info( HWND hwnd ) { static const WCHAR SZ_CONTEXT_NAME[] = {'W','i','n','e',' ','T','a','b','l','e','t',' ','C','o','n','t','e','x','t',0}; static const WCHAR SZ_DEVICE_NAME[] = {'W','i','n','e',' ','T','a','b','l','e','t',' ','D','e','v','i','c','e',0}; @@ -1546,6 +1546,8 @@ LRESULT X11DRV_WintabProc( HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam, vo return tablet_attach_queue( hwnd ); case NtUserWintabInfo: return get_tablet_info( wparam, lparam, buffer ); + case NtUserWintabInit: + return load_tablet_info( hwnd ); case NtUserWintabPacket: *(WTPACKET *)buffer = gMsgPacket; return 1; diff --git a/dlls/winex11.drv/x11drv.h b/dlls/winex11.drv/x11drv.h index b6ea393f480..6b7f5c263f6 100644 --- a/dlls/winex11.drv/x11drv.h +++ b/dlls/winex11.drv/x11drv.h @@ -896,10 +896,6 @@ static inline BOOL is_window_rect_mapped( const RECT *rect ) max( rect->bottom, rect->top + 1 ) > virtual_rect.top); }
-/* unixlib interface */ - -extern NTSTATUS x11drv_tablet_load_info( void *arg ); - /* GDI helpers */
static inline BOOL lp_to_dp( HDC hdc, POINT *points, INT count ) diff --git a/dlls/winex11.drv/x11drv_main.c b/dlls/winex11.drv/x11drv_main.c index 35cb08da5a6..1343accc47d 100644 --- a/dlls/winex11.drv/x11drv_main.c +++ b/dlls/winex11.drv/x11drv_main.c @@ -806,7 +806,6 @@ BOOL X11DRV_SystemParametersInfo( UINT action, UINT int_param, void *ptr_param, const unixlib_entry_t __wine_unix_call_funcs[] = { x11drv_init, - x11drv_tablet_load_info, };
@@ -818,7 +817,6 @@ C_ASSERT( ARRAYSIZE(__wine_unix_call_funcs) == unix_funcs_count ); const unixlib_entry_t __wine_unix_call_wow64_funcs[] = { x11drv_init, - x11drv_tablet_load_info, };
C_ASSERT( ARRAYSIZE(__wine_unix_call_wow64_funcs) == unix_funcs_count ); diff --git a/dlls/wintab32/context.c b/dlls/wintab32/context.c index ec243b7b2cc..4e19a93cc37 100644 --- a/dlls/wintab32/context.c +++ b/dlls/wintab32/context.c @@ -149,7 +149,7 @@ static inline BOOL LoadTablet(void)
if (loaded == TI_START) { - if (pLoadTabletInfo && pLoadTabletInfo(hwndDefault)) + if (NtUserMessageCall(hwndDefault, NtUserWintabInit, 0, 0, NULL, NtUserWintabDriverCall, FALSE)) { TRACE("Initialized the tablet to hwnd %p\n", hwndDefault); loaded = TI_OK; diff --git a/dlls/wintab32/wintab32.c b/dlls/wintab32/wintab32.c index f9860244cac..15040b9ca9c 100644 --- a/dlls/wintab32/wintab32.c +++ b/dlls/wintab32/wintab32.c @@ -42,8 +42,6 @@ static CRITICAL_SECTION_DEBUG csTablet_debug = }; CRITICAL_SECTION csTablet = { &csTablet_debug, -1, 0, 0, 0, 0 };
-int (CDECL *pLoadTabletInfo)(HWND hwnddefault) = NULL; - static LRESULT WINAPI TABLET_WindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam);
@@ -66,30 +64,6 @@ static VOID TABLET_Unregister(void) UnregisterClassW(L"WineTabletClass", NULL); }
-static HMODULE load_graphics_driver(void) -{ - static const WCHAR key_pathW[] = L"System\CurrentControlSet\Control\Video\{"; - static const WCHAR displayW[] = L"}\0000"; - - HMODULE ret = 0; - HKEY hkey; - DWORD size; - WCHAR path[MAX_PATH]; - WCHAR key[ARRAY_SIZE(key_pathW) + ARRAY_SIZE(displayW) + 40]; - UINT guid_atom = HandleToULong( GetPropW( GetDesktopWindow(), L"__wine_display_device_guid" )); - - if (!guid_atom) return 0; - memcpy( key, key_pathW, sizeof(key_pathW) ); - if (!GlobalGetAtomNameW( guid_atom, key + lstrlenW(key), 40 )) return 0; - lstrcatW( key, displayW ); - if (RegOpenKeyW( HKEY_LOCAL_MACHINE, key, &hkey )) return 0; - size = sizeof(path); - if (!RegQueryValueExW( hkey, L"GraphicsDriver", NULL, NULL, (BYTE *)path, &size )) ret = LoadLibraryW( path ); - RegCloseKey( hkey ); - TRACE( "%s %p\n", debugstr_w(path), ret ); - return ret; -} - BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD fdwReason, LPVOID lpReserved) { TRACE("%p, %lx, %p\n",hInstDLL,fdwReason,lpReserved); @@ -101,12 +75,7 @@ BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD fdwReason, LPVOID lpReserved) TABLET_Register(); hwndDefault = CreateWindowW(L"WineTabletClass", L"Tablet", WS_POPUPWINDOW,0,0,0,0,0,0,hInstDLL,0); - if (hwndDefault) - { - HMODULE module = load_graphics_driver(); - pLoadTabletInfo = (void *)GetProcAddress(module, "LoadTabletInfo"); - } - else + if (!hwndDefault) return FALSE; break; case DLL_PROCESS_DETACH: diff --git a/dlls/wintab32/wintab_internal.h b/dlls/wintab32/wintab_internal.h index 1c13df74402..b4b76c69a98 100644 --- a/dlls/wintab32/wintab_internal.h +++ b/dlls/wintab32/wintab_internal.h @@ -150,9 +150,6 @@ int TABLET_PostTabletMessage(LPOPENCONTEXT newcontext, UINT msg, WPARAM wParam, LPARAM lParam, BOOL send_always); LPOPENCONTEXT AddPacketToContextQueue(LPWTPACKET packet, HWND hwnd);
-/* X11drv functions */ -extern int (CDECL *pLoadTabletInfo)(HWND hwnddefault); - extern HWND hwndDefault; extern CRITICAL_SECTION csTablet;
From: Jacek Caban jacek@codeweavers.com
--- dlls/winex11.drv/Makefile.in | 1 - dlls/winex11.drv/dllmain.c | 8 ++------ dlls/winex11.drv/unixlib.h | 29 ----------------------------- dlls/winex11.drv/x11drv.h | 3 ++- dlls/winex11.drv/x11drv_main.c | 6 ------ 5 files changed, 4 insertions(+), 43 deletions(-) delete mode 100644 dlls/winex11.drv/unixlib.h
diff --git a/dlls/winex11.drv/Makefile.in b/dlls/winex11.drv/Makefile.in index 9806dd350e9..53ea4c794d7 100644 --- a/dlls/winex11.drv/Makefile.in +++ b/dlls/winex11.drv/Makefile.in @@ -1,6 +1,5 @@ MODULE = winex11.drv UNIXLIB = winex11.so -IMPORTS = uuid user32 gdi32 win32u UNIX_CFLAGS = $(X_CFLAGS) UNIX_LIBS = -lwin32u $(X_LIBS) $(PTHREAD_LIBS) -lm
diff --git a/dlls/winex11.drv/dllmain.c b/dlls/winex11.drv/dllmain.c index 2e96b920606..ae7084dd6c3 100644 --- a/dlls/winex11.drv/dllmain.c +++ b/dlls/winex11.drv/dllmain.c @@ -21,9 +21,7 @@ #include <stdarg.h> #include "windef.h" #include "winbase.h" -#include "ntgdi.h" -#include "unixlib.h" -#include "wine/debug.h" +#include "wine/unixlib.h"
BOOL WINAPI DllMain( HINSTANCE instance, DWORD reason, void *reserved ) { @@ -31,7 +29,5 @@ BOOL WINAPI DllMain( HINSTANCE instance, DWORD reason, void *reserved )
DisableThreadLibraryCalls( instance ); if (__wine_init_unix_call()) return FALSE; - if (X11DRV_CALL( init, NULL )) return FALSE; - - return TRUE; + return !WINE_UNIX_CALL( 0, NULL ); } diff --git a/dlls/winex11.drv/unixlib.h b/dlls/winex11.drv/unixlib.h deleted file mode 100644 index 5da7abc1bfd..00000000000 --- a/dlls/winex11.drv/unixlib.h +++ /dev/null @@ -1,29 +0,0 @@ -/* - * Copyright 2022 Jacek Caban for CodeWeavers - * - * This library is free software; you can redistribute it and/or - * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation; either - * version 2.1 of the License, or (at your option) any later version. - * - * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - * Lesser General Public License for more details. - * - * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA - */ - -#include "ntuser.h" -#include "shlobj.h" -#include "wine/unixlib.h" - -enum x11drv_funcs -{ - unix_init, - unix_funcs_count, -}; - -#define X11DRV_CALL(func, params) WINE_UNIX_CALL( unix_ ## func, params ) diff --git a/dlls/winex11.drv/x11drv.h b/dlls/winex11.drv/x11drv.h index 6b7f5c263f6..a71607e9e97 100644 --- a/dlls/winex11.drv/x11drv.h +++ b/dlls/winex11.drv/x11drv.h @@ -63,8 +63,9 @@ typedef int Status; #include "windef.h" #include "winbase.h" #include "ntgdi.h" +#include "shlobj.h" +#include "wine/unixlib.h" #include "wine/gdi_driver.h" -#include "unixlib.h" #include "wine/list.h" #include "wine/debug.h" #include "mwm.h" diff --git a/dlls/winex11.drv/x11drv_main.c b/dlls/winex11.drv/x11drv_main.c index 1343accc47d..6616f9fb7d0 100644 --- a/dlls/winex11.drv/x11drv_main.c +++ b/dlls/winex11.drv/x11drv_main.c @@ -808,10 +808,6 @@ const unixlib_entry_t __wine_unix_call_funcs[] = x11drv_init, };
- -C_ASSERT( ARRAYSIZE(__wine_unix_call_funcs) == unix_funcs_count ); - - #ifdef _WIN64
const unixlib_entry_t __wine_unix_call_wow64_funcs[] = @@ -819,6 +815,4 @@ const unixlib_entry_t __wine_unix_call_wow64_funcs[] = x11drv_init, };
-C_ASSERT( ARRAYSIZE(__wine_unix_call_wow64_funcs) == unix_funcs_count ); - #endif /* _WIN64 */
What difference does it make?
I think we should maybe consider dropping wintab32 entirely, it's not a Windows dll and I believe it never even was, and instead rely on touch / pointer messages (which might need some work still but which can be tested through virtual hid devices).
On Wed Oct 29 20:13:05 2025 +0000, Rémi Bernon wrote:
What difference does it make? I think we should maybe consider dropping wintab32 entirely, it's not a Windows dll and I believe it never even was, and instead rely on touch / pointer messages (which might need some work still but which can be tested through virtual hid devices).
This dll was present till windows 8, for backward compatibility with graphic tablets it should still be there.
According to my research, wintab isn't distributed by Microsoft, but it *is* installed as part of the Wacom tablet drivers. I don't think we want to rely on using native drivers, since that'll basically force Wine to have lower level access to the device and shut out everything else. We may want to reimplement wintab32 on top of pointer messages, but I don't think we want to get rid of it.
What difference does it make?
It allows us to get rid of the remaining PE driver exports and remove assumptions about those drivers from PE code (wintab32). Removing `load_graphics_driver` from wintab32 seems like a good enough reason on its own.
There might be a better way to handle this using messages, but I went with something simple. Rewriting wintab32 doesn’t seem appealing given the complexity to benefit ratio.