mirror of
git://source.winehq.org/git/wine.git
synced 2024-10-31 10:41:12 +00:00
JoystickAImpl_Unacquire should return DI_NOEFFECT if the device is not
in an acquired state.
This commit is contained in:
parent
e40da9f17c
commit
ab4e40cf0f
2 changed files with 6 additions and 2 deletions
|
@ -306,8 +306,10 @@ static HRESULT WINAPI JoystickAImpl_Unacquire(LPDIRECTINPUTDEVICE8A iface)
|
|||
if (This->joyfd!=-1) {
|
||||
close(This->joyfd);
|
||||
This->joyfd = -1;
|
||||
return DI_OK;
|
||||
}
|
||||
return DI_OK;
|
||||
else
|
||||
return DI_NOEFFECT;
|
||||
}
|
||||
|
||||
#define map_axis(val) ((val+32768)*(This->lMax-This->lMin)/65536+This->lMin)
|
||||
|
|
|
@ -432,8 +432,10 @@ static HRESULT WINAPI JoystickAImpl_Unacquire(LPDIRECTINPUTDEVICE8A iface)
|
|||
if (This->joyfd!=-1) {
|
||||
close(This->joyfd);
|
||||
This->joyfd = -1;
|
||||
return DI_OK;
|
||||
}
|
||||
return DI_OK;
|
||||
else
|
||||
return DI_NOEFFECT;
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
Loading…
Reference in a new issue