[DINPUT] Sync with Wine 3.0. CORE-14225

This commit is contained in:
Amine Khaldi 2018-01-21 22:26:41 +01:00
parent 56fc552f24
commit 0b35adc274
5 changed files with 28 additions and 27 deletions

View file

@ -976,9 +976,9 @@ HRESULT WINAPI IDirectInputDevice2WImpl_Acquire(LPDIRECTINPUTDEVICE8W iface)
EnterCriticalSection(&This->crit);
res = This->acquired ? S_FALSE : DI_OK;
This->acquired = 1;
LeaveCriticalSection(&This->crit);
if (res == DI_OK)
check_dinput_hooks(iface, TRUE);
check_dinput_hooks(iface);
LeaveCriticalSection(&This->crit);
return res;
}
@ -1004,9 +1004,9 @@ HRESULT WINAPI IDirectInputDevice2WImpl_Unacquire(LPDIRECTINPUTDEVICE8W iface)
EnterCriticalSection(&This->crit);
res = !This->acquired ? DI_NOEFFECT : DI_OK;
This->acquired = 0;
LeaveCriticalSection(&This->crit);
if (res == DI_OK)
check_dinput_hooks(iface, FALSE);
check_dinput_hooks(iface);
LeaveCriticalSection(&This->crit);
return res;
}