We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 2c9615c commit c580523Copy full SHA for c580523
src/video/emscripten/SDL_emscriptenvideo.c
@@ -769,9 +769,17 @@ static SDL_FullscreenResult Emscripten_SetWindowFullscreen(SDL_VideoDevice *_thi
769
}
770
771
772
+// Assume the first window that calls SDL_SetWindowTitle is the main window.
773
+static SDL_Window *mainWindow = NULL;
774
+
775
static void Emscripten_SetWindowTitle(SDL_VideoDevice *_this, SDL_Window *window)
776
{
- emscripten_set_window_title(window->title);
777
+ if (!mainWindow) {
778
+ mainWindow = window;
779
+ }
780
+ if (mainWindow == window) {
781
+ emscripten_set_window_title(window->title);
782
783
784
785
static bool Emscripten_SetWindowPosition(SDL_VideoDevice *_this, SDL_Window *window)
0 commit comments