From 6b6637fbea0fedcf306d56819476183fb0a1d9d7 Mon Sep 17 00:00:00 2001 From: zeromus Date: Thu, 18 Feb 2021 21:52:30 -0500 Subject: [PATCH] improve xinput availability check which was broken by pointless refactors in 580aa2eaf90ee12925973bf7397d5fb215925d9a (but it should be even more robust than before, now). fixes #23 --- src/BizHawk.Bizware.DirectX/GamePad360.cs | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/BizHawk.Bizware.DirectX/GamePad360.cs b/src/BizHawk.Bizware.DirectX/GamePad360.cs index d58ee04f9c..676dc89d7e 100644 --- a/src/BizHawk.Bizware.DirectX/GamePad360.cs +++ b/src/BizHawk.Bizware.DirectX/GamePad360.cs @@ -58,12 +58,11 @@ namespace BizHawk.Bizware.DirectX IsAvailable = libraryHandle != IntPtr.Zero; // don't remove this code. it's important to catch errors on systems with broken xinput installs. - // (probably, checking for the library was adequate, but let's not get rid of this anyway) if (IsAvailable) _ = new Controller(UserIndex.One).IsConnected; } catch { - // ignored + IsAvailable = false; } }