mirror of
https://github.com/yawut/SDL.git
synced 2026-04-24 23:37:09 -05:00
Don't bother calling SDL_SYS_HapticEffectType() at all for XInput devices.
This commit is contained in:
parent
79a72325c6
commit
4fdc8805dd
|
|
@ -1202,10 +1202,13 @@ SDL_SYS_HapticNewEffect(SDL_Haptic * haptic, struct haptic_effect *effect,
|
|||
SDL_HapticEffect * base)
|
||||
{
|
||||
HRESULT ret;
|
||||
REFGUID type = SDL_SYS_HapticEffectType(base);
|
||||
REFGUID type = NULL;
|
||||
|
||||
if ((type == NULL) && (!haptic->hwdata->bXInputHaptic)) {
|
||||
goto err_hweffect;
|
||||
if (!haptic->hwdata->bXInputHaptic) {
|
||||
type = SDL_SYS_HapticEffectType(base);
|
||||
if (type == NULL) {
|
||||
goto err_hweffect;
|
||||
}
|
||||
}
|
||||
|
||||
/* Alloc the effect. */
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user