Files
SDL/src/joystick
Christian Semmler 5be888591c emscripten: Fix navigator.getGamepads crash in worker threads
The three EM_JS functions (SDL_GetEmscriptenJoystickVendor,
SDL_GetEmscriptenJoystickProduct, SDL_IsEmscriptenJoystickXInput)
call navigator.getGamepads() which is only available on the main
browser thread. With PROXY_TO_PTHREAD, the joystick callbacks are
dispatched to a worker where the Gamepad API is not available,
causing a TypeError.

Convert these from EM_JS to static functions using
MAIN_THREAD_EM_ASM_INT, which proxies the JavaScript execution to
the main browser thread. This matches the pattern already used by
other navigator.getGamepads() calls in the same file.

(cherry picked from commit be8643f739)
2026-04-02 19:37:33 -07:00
..
2026-01-01 09:48:19 -08:00
2026-01-01 09:48:19 -08:00
2026-01-01 09:48:19 -08:00
2026-04-02 17:10:59 -07:00
2026-01-01 09:48:19 -08:00
2026-01-23 16:02:27 -08:00
2026-01-01 09:48:19 -08:00
2026-01-01 09:48:19 -08:00
2026-01-01 09:48:19 -08:00
2026-01-01 09:48:19 -08:00
2026-01-01 09:48:19 -08:00
2026-01-01 09:48:19 -08:00
2026-01-01 09:48:19 -08:00