From: "Rémi Bernon" Subject: [PATCH 6/6] xinput1_3: Use the internal XInput device interface. Message-Id: <20210826055904.828578-6-rbernon@codeweavers.com> Date: Thu, 26 Aug 2021 07:59:04 +0200 In-Reply-To: <20210826055904.828578-1-rbernon@codeweavers.com> References: <20210826055904.828578-1-rbernon@codeweavers.com> Signed-off-by: Rémi Bernon --- 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.33.0