Merged r3029:3030 from branches/SDL-1.2: Mac OS X joystick axis fix.

--HG--
extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/trunk%402321
This commit is contained in:
Ryan C. Gordon 2007-05-29 12:14:16 +00:00
parent b9b86fb09d
commit 68348a9ff7

View file

@ -258,12 +258,11 @@ HIDGetElementInfo(CFTypeRef refElement, recElement * pElement)
pElement->cookie = (IOHIDElementCookie) number;
refType = CFDictionaryGetValue(refElement, CFSTR(kIOHIDElementMinKey));
if (refType && CFNumberGetValue(refType, kCFNumberLongType, &number))
pElement->min = number;
pElement->minReport = pElement->min = number;
pElement->maxReport = pElement->min;
refType = CFDictionaryGetValue(refElement, CFSTR(kIOHIDElementMaxKey));
if (refType && CFNumberGetValue(refType, kCFNumberLongType, &number))
pElement->max = number;
pElement->minReport = pElement->max;
pElement->maxReport = pElement->max = number;
/*
TODO: maybe should handle the following stuff somehow?