Fabian Maurer : user32: Add stub for GetPointerDevices.

Alexandre Julliard julliard at winehq.org
Mon Jun 11 13:10:49 CDT 2018


Module: wine
Branch: master
Commit: 66180389f8f96d87fd711d4fd03f462bdf5daadf
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=66180389f8f96d87fd711d4fd03f462bdf5daadf

Author: Fabian Maurer <dark.shadow4 at web.de>
Date:   Thu Jun  7 23:46:55 2018 +0200

user32: Add stub for GetPointerDevices.

Signed-off-by: Fabian Maurer <dark.shadow4 at web.de>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 .../api-ms-win-rtcore-ntuser-wmpointer-l1-1-0.spec   |  2 +-
 dlls/user32/misc.c                                   | 18 ++++++++++++++++++
 dlls/user32/user32.spec                              |  1 +
 include/winuser.h                                    | 20 ++++++++++++++++++++
 4 files changed, 40 insertions(+), 1 deletion(-)

diff --git a/dlls/api-ms-win-rtcore-ntuser-wmpointer-l1-1-0/api-ms-win-rtcore-ntuser-wmpointer-l1-1-0.spec b/dlls/api-ms-win-rtcore-ntuser-wmpointer-l1-1-0/api-ms-win-rtcore-ntuser-wmpointer-l1-1-0.spec
index 72cfe3d..3a043dc 100644
--- a/dlls/api-ms-win-rtcore-ntuser-wmpointer-l1-1-0/api-ms-win-rtcore-ntuser-wmpointer-l1-1-0.spec
+++ b/dlls/api-ms-win-rtcore-ntuser-wmpointer-l1-1-0/api-ms-win-rtcore-ntuser-wmpointer-l1-1-0.spec
@@ -4,7 +4,7 @@
 @ stub GetPointerDevice
 @ stub GetPointerDeviceProperties
 @ stub GetPointerDeviceRects
-@ stub GetPointerDevices
+@ stdcall GetPointerDevices(ptr ptr) user32.GetPointerDevices
 @ stub GetPointerFrameInfo
 @ stub GetPointerFrameInfoHistory
 @ stub GetPointerFramePenInfo
diff --git a/dlls/user32/misc.c b/dlls/user32/misc.c
index c3f4030..dfdd599 100644
--- a/dlls/user32/misc.c
+++ b/dlls/user32/misc.c
@@ -846,6 +846,24 @@ BOOL WINAPI RegisterPointerDeviceNotifications(HWND hwnd, BOOL notifyrange)
     return TRUE;
 }
 
+/**********************************************************************
+ * GetPointerDevices [USER32.@]
+ */
+BOOL WINAPI GetPointerDevices(UINT32 *device_count, POINTER_DEVICE_INFO *devices)
+{
+    FIXME("(%p %p): partial stub\n", device_count, devices);
+
+    if (!device_count)
+        return FALSE;
+
+    if (devices)
+        return FALSE;
+
+    *device_count = 0;
+    return TRUE;
+}
+
+
 static const WCHAR imeW[] = {'I','M','E',0};
 const struct builtin_class_descr IME_builtin_class =
 {
diff --git a/dlls/user32/user32.spec b/dlls/user32/user32.spec
index 2e5b203..7f652ee 100644
--- a/dlls/user32/user32.spec
+++ b/dlls/user32/user32.spec
@@ -354,6 +354,7 @@
 @ stdcall GetOpenClipboardWindow()
 @ stdcall GetParent(long)
 @ stdcall GetPhysicalCursorPos(ptr)
+@ stdcall GetPointerDevices(ptr ptr)
 @ stdcall GetPriorityClipboardFormat(ptr long)
 @ stdcall GetProcessDefaultLayout(ptr)
 @ stdcall GetProcessDpiAwarenessInternal(long ptr)
diff --git a/include/winuser.h b/include/winuser.h
index 648efbe..f546a4a 100644
--- a/include/winuser.h
+++ b/include/winuser.h
@@ -3357,6 +3357,26 @@ typedef struct tagGESTUREINFO {
 } GESTUREINFO, *PGESTUREINFO;
 typedef GESTUREINFO const * PCGESTUREINFO;
 
+#define POINTER_DEVICE_PRODUCT_STRING_MAX 520
+
+typedef enum tagPOINTER_DEVICE_TYPE {
+    POINTER_DEVICE_TYPE_INTEGRATED_PEN = 0x00000001,
+    POINTER_DEVICE_TYPE_EXTERNAL_PEN   = 0x00000002,
+    POINTER_DEVICE_TYPE_TOUCH          = 0x00000003,
+    POINTER_DEVICE_TYPE_TOUCH_PAD      = 0x00000004,
+    POINTER_DEVICE_TYPE_MAX            = 0xFFFFFFFF
+} POINTER_DEVICE_TYPE;
+
+typedef struct tagPOINTER_DEVICE_INFO {
+    DWORD               displayOrientation;
+    HANDLE              device;
+    POINTER_DEVICE_TYPE pointerDeviceType;
+    HMONITOR            monitor;
+    ULONG               startingCursorId;
+    USHORT              maxActiveContacts;
+    WCHAR               productString[POINTER_DEVICE_PRODUCT_STRING_MAX];
+} POINTER_DEVICE_INFO;
+
 #if defined(_WINGDI_) && !defined(NOGDI)
 WINUSERAPI LONG        WINAPI ChangeDisplaySettingsA(LPDEVMODEA,DWORD);
 WINUSERAPI LONG        WINAPI ChangeDisplaySettingsW(LPDEVMODEW,DWORD);




More information about the wine-cvs mailing list