Find just joysticks and gamepads (as opposed to, say, USB Audio devices), in

the MacOSX/Darwin joystick initialization code.
This commit is contained in:
Ryan C. Gordon
2003-05-22 06:41:54 +00:00
parent 8b29e98df8
commit c0a9be475c

View File

@@ -647,9 +647,9 @@ int SDL_SYS_JoystickInit(void)
/* Filter device list to non-keyboard/mouse stuff */
if ( device->usagePage == kHIDPage_GenericDesktop &&
(device->usage == kHIDUsage_GD_Keyboard ||
device->usage == kHIDUsage_GD_Mouse)) {
(device->usage != kHIDUsage_GD_Joystick ||
device->usage != kHIDUsage_GD_Gamepad)) {
/* release memory for the device */
HIDDisposeDevice (&device);
DisposePtr((Ptr)device);