Use 'contains' method
This commit is contained in:
1 parent
5af0ae25e6
commit
618b41a459
31 files changed
+46
-52
No files matched your search
@@ -44,7 +44,7 @@ void InitJoystick(IDirectInput8* const idi8, HWND hwnd)
|
||||
for (DIDEVICEINSTANCE& joystick : joysticks)
|
||||
{
|
||||
// Skip XInput Devices
|
||||
if (xinput_guids.count(joystick.guidProduct.Data1))
|
||||
if (xinput_guids.contains(joystick.guidProduct.Data1))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
@@ -52,7 +52,7 @@ void InitJoystick(IDirectInput8* const idi8, HWND hwnd)
|
||||
// Skip devices we are already using.
|
||||
{
|
||||
std::lock_guard lk(s_guids_mutex);
|
||||
if (s_guids_in_use.count(joystick.guidInstance))
|
||||
if (s_guids_in_use.contains(joystick.guidInstance))
|
||||
{
|
||||
continue;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user