| 291 | |
| 292 | |
| 293 | static CFArrayRef get_array_property(IOHIDDeviceRef device, CFStringRef key) |
| 294 | { |
| 295 | CFTypeRef ref = IOHIDDeviceGetProperty(device, key); |
| 296 | if (ref != NULL && CFGetTypeID(ref) == CFArrayGetTypeID()) { |
| 297 | return (CFArrayRef)ref; |
| 298 | } else { |
| 299 | return NULL; |
| 300 | } |
| 301 | } |
| 302 | |
| 303 | static int32_t get_int_property(IOHIDDeviceRef device, CFStringRef key) |
| 304 | { |