From dd7c1450c30ef9e2a7ba19c65e627b10445751b8 Mon Sep 17 00:00:00 2001 From: Christian Semmler Date: Mon, 10 Jun 2024 11:43:45 -0400 Subject: [PATCH] Fix minimize/maximize suspension --- ISLE/isleapp.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ISLE/isleapp.cpp b/ISLE/isleapp.cpp index 4d365f26..a73ebf2a 100644 --- a/ISLE/isleapp.cpp +++ b/ISLE/isleapp.cpp @@ -310,15 +310,17 @@ int SDL_AppEvent(void* appstate, const SDL_Event* event) // [library:window] // Remaining functionality to be implemented: - // Full screen - crashes when minimizing/maximizing + // Full screen - crashes when minimizing/maximizing, but this will probably be fixed once DirectDraw is replaced // WM_TIMER - use SDL_Timer functionality instead switch (event->type) { case SDL_EVENT_WINDOW_FOCUS_GAINED: g_isle->SetWindowActive(TRUE); + Lego()->StopTimer(); break; case SDL_EVENT_WINDOW_FOCUS_LOST: g_isle->SetWindowActive(FALSE); + Lego()->StartTimer(); break; case SDL_EVENT_WINDOW_CLOSE_REQUESTED: if (!g_closed) {