From 8e1f4bafb449ee6cc223dd4c62a45deb791dc47e Mon Sep 17 00:00:00 2001 From: Sam Clegg Date: Tue, 6 May 2025 13:04:37 -0700 Subject: [PATCH] [emscripten] Remove referenc to Module['createContext'] The Module interface is the one used by the outside world. This code is inside the module itself so can use the internal name, avoiding the need to export this function on the Module at all. See https://github.com/emscripten-core/emscripten/pull/24269 --- src/video/emscripten/SDL_emscriptenframebuffer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/video/emscripten/SDL_emscriptenframebuffer.c b/src/video/emscripten/SDL_emscriptenframebuffer.c index 503fac6804..89fae738d7 100644 --- a/src/video/emscripten/SDL_emscriptenframebuffer.c +++ b/src/video/emscripten/SDL_emscriptenframebuffer.c @@ -78,7 +78,7 @@ bool Emscripten_UpdateWindowFramebuffer(SDL_VideoDevice *_this, SDL_Window *wind if (!Module['SDL3']) Module['SDL3'] = {}; var SDL3 = Module['SDL3']; if (SDL3.ctxCanvas !== canvas) { - SDL3.ctx = Module['createContext'](canvas, false, true); + SDL3.ctx = Browser.createContext(canvas, false, true); SDL3.ctxCanvas = canvas; } if (SDL3.w !== w || SDL3.h !== h || SDL3.imageCtx !== SDL3.ctx) {