summaryrefslogtreecommitdiff
path: root/indra/llwindow/llwindowmacosx.cpp
diff options
context:
space:
mode:
authorAndrey Lihatskiy <alihatskiy@productengine.com>2023-11-30 13:54:39 +0200
committerAndrey Lihatskiy <alihatskiy@productengine.com>2023-11-30 14:26:45 +0200
commit8b9c44b2155785ead99c7e99a21348a0712ccb15 (patch)
treea51e89a87f7c89812368d9da4733e510302ea1d4 /indra/llwindow/llwindowmacosx.cpp
parent27dae1d96753634c40619af8bc5b982f5238289b (diff)
Mac buildfix
Diffstat (limited to 'indra/llwindow/llwindowmacosx.cpp')
-rw-r--r--indra/llwindow/llwindowmacosx.cpp34
1 files changed, 16 insertions, 18 deletions
diff --git a/indra/llwindow/llwindowmacosx.cpp b/indra/llwindow/llwindowmacosx.cpp
index 66b9a5d060..41665419aa 100644
--- a/indra/llwindow/llwindowmacosx.cpp
+++ b/indra/llwindow/llwindowmacosx.cpp
@@ -2246,29 +2246,27 @@ static void get_devices(std::list<HidDevice> &list_of_devices,
{
HidDevice device = populate_device( io_obj );
- if (debugLoggingEnabled("Joystick"))
+ // Should match ndof
+ if (device.mAxis >= 3
+ || (device.mUsagePage == kHIDPage_GenericDesktop
+ && (device.mUsage == kHIDUsage_GD_MultiAxisController
+ || device.mUsage == kHIDUsage_GD_GamePad
+ || device.mUsage == kHIDUsage_GD_Joystick))
+ || (device.mUsagePage == kHIDPage_Game
+ && device.mUsage == kHIDUsage_Game_3DGameController)
+ || strstr(device.mManufacturer, "3Dconnexion"))
{
list_of_devices.push_back(device);
- LL_DEBUGS("Joystick") << "Device axises: " << (S32)device.mAxis
- << "Device HIDUsepage: " << (S32)device.mUsagePage
- << "Device HIDUsage: " << (S32)device.mUsage
- << LL_ENDL;
}
else
{
- // Should match ndof
- if (device.mAxis >= 3
- || (device.mUsagePage == kHIDPage_GenericDesktop
- && (device.mUsage == kHIDUsage_GD_MultiAxisController
- || device.mUsage == kHIDUsage_GD_GamePad
- || device.mUsage == kHIDUsage_GD_Joystick))
- || (device.mUsagePage == kHIDPage_Game
- && device.mUsage == kHIDUsage_Game_3DGameController)
- || strstr(device.mManufacturer, "3Dconnexion"))
- {
- list_of_devices.push_back(device);
- }
- }
+ LL_DEBUGS("Joystick");
+ list_of_devices.push_back(device);
+ LL_CONT << "Device axes: " << (S32)device.mAxis
+ << " Device HIDUsepage: " << (S32)device.mUsagePage
+ << " Device HIDUsage: " << (S32)device.mUsage;
+ LL_ENDL;
+ }
// release the device object, it is no longer needed