Linux: Fix joystick without buttons being ignored

Joysticks in Linux without buttons were ignored by device enumeration.
Remove the mandatory button attribute from detection.

Fixes #2042
Closes #2043
This commit is contained in:
Björn Hempel 2022-02-06 13:32:10 +01:00 committed by Camilla Löwy
parent c50d53160f
commit c424fe5589

View File

@ -157,7 +157,7 @@ static GLFWbool openJoystickDevice(const char* path)
}
// Ensure this device supports the events expected of a joystick
if (!isBitSet(EV_KEY, evBits) || !isBitSet(EV_ABS, evBits))
if (!isBitSet(EV_ABS, evBits))
{
close(linjs.fd);
return GLFW_FALSE;