[PATCH 5/5] xinput1_3: Use the internal XInput device interface.
Rémi Bernon
rbernon at codeweavers.com
Wed Aug 18 02:31:14 CDT 2021
Signed-off-by: Rémi Bernon <rbernon at codeweavers.com>
---
dlls/xinput1_3/main.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/dlls/xinput1_3/main.c b/dlls/xinput1_3/main.c
index 4770b64681e..bc5d91109b0 100644
--- a/dlls/xinput1_3/main.c
+++ b/dlls/xinput1_3/main.c
@@ -43,6 +43,8 @@
#include "wine/debug.h"
+DEFINE_GUID(GUID_DEVINTERFACE_XINPUT, 0xec87f1e3, 0xc13b, 0x4100, 0xb5, 0xf7, 0x8b, 0x84, 0xd5, 0x42, 0x60, 0xcb);
+
/* Not defined in the headers, used only by XInputGetStateEx */
#define XINPUT_GAMEPAD_GUIDE 0x0400
@@ -324,7 +326,7 @@ static void update_controller_list(void)
GUID guid;
int i;
- HidD_GetHidGuid(&guid);
+ guid = GUID_DEVINTERFACE_XINPUT;
set = SetupDiGetClassDevsW(&guid, NULL, NULL, DIGCF_DEVICEINTERFACE | DIGCF_PRESENT);
detail->cbSize = sizeof(*detail);
@@ -335,8 +337,6 @@ static void update_controller_list(void)
if (!SetupDiGetDeviceInterfaceDetailW(set, &iface, detail, sizeof(buffer), NULL, NULL))
continue;
- if (!wcsstr(detail->DevicePath, L"IG_")) continue;
-
if (find_opened_device(detail, &i)) continue; /* already opened */
if (i == XUSER_MAX_COUNT) break; /* no more slots */
--
2.32.0
More information about the wine-devel
mailing list