dinput: Fix processing of custom format.
This commit is contained in:
parent
878d5cc069
commit
1056c881e1
|
@ -327,8 +327,8 @@ DataFormat *create_DataFormat(const DIDATAFORMAT *wine_format, LPCDIDATAFORMAT a
|
|||
(DIDFT_GETINSTANCE(asked_format->rgodf[j].dwType) == DIDFT_GETINSTANCE(wine_format->rgodf[i].dwType)))
|
||||
&&
|
||||
( /* Then if the asked type matches the one Wine provides */
|
||||
wine_format->rgodf[i].dwType & asked_format->rgodf[j].dwType)) {
|
||||
|
||||
DIDFT_GETTYPE(asked_format->rgodf[j].dwType) & wine_format->rgodf[i].dwType))
|
||||
{
|
||||
done[j] = 1;
|
||||
|
||||
TRACE("Matching :\n");
|
||||
|
@ -1009,6 +1009,9 @@ HRESULT WINAPI IDirectInputDevice2AImpl_Escape(
|
|||
HRESULT WINAPI IDirectInputDevice2AImpl_Poll(
|
||||
LPDIRECTINPUTDEVICE8A iface)
|
||||
{
|
||||
IDirectInputDevice2AImpl *This = (IDirectInputDevice2AImpl *)iface;
|
||||
|
||||
if (!This->acquired) return DIERR_NOTACQUIRED;
|
||||
/* Because wine devices do not need to be polled, just return DI_NOEFFECT */
|
||||
return DI_NOEFFECT;
|
||||
}
|
||||
|
|
|
@ -113,7 +113,6 @@ struct JoystickImpl
|
|||
int axes;
|
||||
int buttons;
|
||||
POV povs[4];
|
||||
BOOL overflow;
|
||||
};
|
||||
|
||||
static GUID DInput_Wine_Joystick_GUID = { /* 9e573ed9-7734-11d2-8d4a-23903fb6bdf7 */
|
||||
|
@ -495,7 +494,6 @@ static HRESULT alloc_device(REFGUID rguid, const void *jvt, IDirectInputImpl *di
|
|||
newDevice->base.lpVtbl = jvt;
|
||||
newDevice->base.ref = 1;
|
||||
newDevice->dinput = dinput;
|
||||
newDevice->overflow = FALSE;
|
||||
CopyMemory(&newDevice->base.guid, rguid, sizeof(*rguid));
|
||||
InitializeCriticalSection(&newDevice->base.crit);
|
||||
newDevice->base.crit.DebugInfo->Spare[0] = (DWORD_PTR)"DINPUT_joystick";
|
||||
|
|
Loading…
Reference in New Issue