src/joystick/darwin/SDL_sysjoystick.c
changeset 622 e6d751de784a
parent 621 c3bb1270fa2b
child 623 477917048b91
equal deleted inserted replaced
621:c3bb1270fa2b 622:e6d751de784a
   645 //		if (KERN_SUCCESS != result)
   645 //		if (KERN_SUCCESS != result)
   646 //			HIDReportErrorNum ("IOObjectRelease error with ioHIDDeviceObject.", result);
   646 //			HIDReportErrorNum ("IOObjectRelease error with ioHIDDeviceObject.", result);
   647 
   647 
   648 		/* Filter device list to non-keyboard/mouse stuff */ 
   648 		/* Filter device list to non-keyboard/mouse stuff */ 
   649 		if ( device->usagePage == kHIDPage_GenericDesktop &&
   649 		if ( device->usagePage == kHIDPage_GenericDesktop &&
   650 		     (device->usage != kHIDUsage_GD_Joystick ||
   650 		     (device->usage != kHIDUsage_GD_Joystick &&
   651 		      device->usage != kHIDUsage_GD_GamePad)) {
   651 		      device->usage != kHIDUsage_GD_GamePad)) {
   652 
   652 
   653 			/* release memory for the device */
   653 			/* release memory for the device */
   654 			HIDDisposeDevice (&device);
   654 			HIDDisposeDevice (&device);
   655 			DisposePtr((Ptr)device);
   655 			DisposePtr((Ptr)device);