mirror of
https://github.com/Relintai/sdl2_frt.git
synced 2024-12-20 22:16:49 +01:00
Don't try to call IOS_SupportedHIDDevice() if it's not defined
This commit is contained in:
parent
a063b9fbfb
commit
97782e6c64
@ -526,11 +526,15 @@ GetDeviceInfo(IOHIDDeviceRef hidDevice, recDevice *pDevice)
|
|||||||
static SDL_bool
|
static SDL_bool
|
||||||
JoystickAlreadyKnown(IOHIDDeviceRef ioHIDDeviceObject)
|
JoystickAlreadyKnown(IOHIDDeviceRef ioHIDDeviceObject)
|
||||||
{
|
{
|
||||||
|
recDevice *i;
|
||||||
|
|
||||||
|
#if TARGET_OS_OSX
|
||||||
extern SDL_bool IOS_SupportedHIDDevice(IOHIDDeviceRef device);
|
extern SDL_bool IOS_SupportedHIDDevice(IOHIDDeviceRef device);
|
||||||
if (IOS_SupportedHIDDevice(ioHIDDeviceObject)) {
|
if (IOS_SupportedHIDDevice(ioHIDDeviceObject)) {
|
||||||
return SDL_TRUE;
|
return SDL_TRUE;
|
||||||
}
|
}
|
||||||
recDevice *i;
|
#endif
|
||||||
|
|
||||||
for (i = gpDeviceList; i != NULL; i = i->pNext) {
|
for (i = gpDeviceList; i != NULL; i = i->pNext) {
|
||||||
if (i->deviceRef == ioHIDDeviceObject) {
|
if (i->deviceRef == ioHIDDeviceObject) {
|
||||||
return SDL_TRUE;
|
return SDL_TRUE;
|
||||||
|
@ -1365,7 +1365,6 @@ IOS_JoystickGetGamepadMapping(int device_index, SDL_GamepadMapping *out)
|
|||||||
}
|
}
|
||||||
|
|
||||||
#if TARGET_OS_OSX
|
#if TARGET_OS_OSX
|
||||||
extern SDL_bool IOS_SupportedHIDDevice(IOHIDDeviceRef device);
|
|
||||||
SDL_bool IOS_SupportedHIDDevice(IOHIDDeviceRef device)
|
SDL_bool IOS_SupportedHIDDevice(IOHIDDeviceRef device)
|
||||||
{
|
{
|
||||||
#ifdef SDL_JOYSTICK_MFI
|
#ifdef SDL_JOYSTICK_MFI
|
||||||
|
Loading…
Reference in New Issue
Block a user