diff options
| author | Scott Mansell <phiren@gmail.com> | 2017-08-07 13:44:07 +1200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2017-08-07 13:44:07 +1200 |
| commit | 3b5cad66820441373d8210fb0d40166748fd2a62 (patch) | |
| tree | 031c9f05902626d58201093dec032aee104e41c5 /Source/Core/InputCommon/ControllerInterface | |
| parent | bc11fad6eb8c048ab76833e16aa15ffd7925b938 (diff) | |
| parent | 200fb26148630d59e77f7a1574617b496df082a7 (diff) | |
Merge pull request #5860 from jturcotte/fix-macos-nswitch-axis
Fix axis not working with Switch Pro controller on macOS
Diffstat (limited to 'Source/Core/InputCommon/ControllerInterface')
| -rw-r--r-- | Source/Core/InputCommon/ControllerInterface/OSX/OSXJoystick.mm | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/Source/Core/InputCommon/ControllerInterface/OSX/OSXJoystick.mm b/Source/Core/InputCommon/ControllerInterface/OSX/OSXJoystick.mm index e8595153f2..9bbd953a4b 100644 --- a/Source/Core/InputCommon/ControllerInterface/OSX/OSXJoystick.mm +++ b/Source/Core/InputCommon/ControllerInterface/OSX/OSXJoystick.mm @@ -39,7 +39,10 @@ Joystick::Joystick(IOHIDDeviceRef device, std::string name) } // Axes - NSDictionary* axisDict = @{ @kIOHIDElementTypeKey : @(kIOHIDElementTypeInput_Misc) }; + NSDictionary* axisDict = @{ + @kIOHIDElementTypeKey : @(kIOHIDElementTypeInput_Misc), + @kIOHIDElementUsagePageKey : @(kHIDPage_GenericDesktop) + }; CFArrayRef axes = IOHIDDeviceCopyMatchingElements(m_device, (CFDictionaryRef)axisDict, kIOHIDOptionsTypeNone); |
