Linux: Fix joystick input being disabled

Closes #2192
This commit is contained in:
TheBrokenRail 2022-12-15 14:18:59 -05:00 committed by GitHub
parent dd8a678a66
commit 00967cbb8a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 4 additions and 4 deletions

View File

@ -394,7 +394,7 @@ GLFWbool _glfwConnectWayland(int platformID, _GLFWplatform* platform)
_glfwGetKeyScancodeWayland,
_glfwSetClipboardStringWayland,
_glfwGetClipboardStringWayland,
#if defined(_GLFW_LINUX_JOYSTICK)
#if defined(GLFW_BUILD_LINUX_JOYSTICK)
_glfwInitJoysticksLinux,
_glfwTerminateJoysticksLinux,
_glfwPollJoystickLinux,

View File

@ -1184,7 +1184,7 @@ GLFWbool _glfwConnectX11(int platformID, _GLFWplatform* platform)
_glfwGetKeyScancodeX11,
_glfwSetClipboardStringX11,
_glfwGetClipboardStringX11,
#if defined(_GLFW_LINUX_JOYSTICK)
#if defined(GLFW_BUILD_LINUX_JOYSTICK)
_glfwInitJoysticksLinux,
_glfwTerminateJoysticksLinux,
_glfwPollJoystickLinux,

View File

@ -88,7 +88,7 @@ static GLFWbool waitForAnyEvent(double* timeout)
{ _glfw.x11.emptyEventPipe[0], POLLIN }
};
#if defined(_GLFW_LINUX_JOYSTICK)
#if defined(GLFW_BUILD_LINUX_JOYSTICK)
if (_glfw.joysticksInitialized)
fds[count++] = (struct pollfd) { _glfw.linjs.inotify, POLLIN };
#endif
@ -2783,7 +2783,7 @@ void _glfwPollEventsX11(void)
{
drainEmptyEvents();
#if defined(_GLFW_LINUX_JOYSTICK)
#if defined(GLFW_BUILD_LINUX_JOYSTICK)
if (_glfw.joysticksInitialized)
_glfwDetectJoystickConnectionLinux();
#endif