From 60d7ead565421610b271c29939277fc9ac6cb2d7 Mon Sep 17 00:00:00 2001 From: laqieer Date: Sun, 7 Aug 2022 19:00:28 +0000 Subject: [PATCH] Fix menu state after playing a movie Fix the state of the File -> Play -> Start/Stop menu after playing a movie by calling systemStopGamePlayback() when the playback stops. Signed-off-by: Rafael Kitover --- src/wx/sys.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/wx/sys.cpp b/src/wx/sys.cpp index 238819d9..e748715e 100644 --- a/src/wx/sys.cpp +++ b/src/wx/sys.cpp @@ -401,8 +401,7 @@ uint32_t systemReadJoypad(int joy) uint32_t gf, jp; if (game_file.Read(&gf, sizeof(gf)) != sizeof(gf) || game_file.Read(&jp, sizeof(jp)) != sizeof(jp)) { - game_file.Close(); - game_playback = false; + systemStopGamePlayback(); wxString msg(_("Playback ended")); systemScreenMessage(msg); break; @@ -421,8 +420,7 @@ uint32_t systemReadJoypad(int joy) uint32_t gf, jp; if (game_file.Read(&gf, sizeof(gf)) != sizeof(gf) || game_file.Read(&jp, sizeof(jp)) != sizeof(jp)) { - game_file.Close(); - game_playback = false; + systemStopGamePlayback(); wxString msg(_("Playback ended")); systemScreenMessage(msg); break;