Fixed an issue where starting the media viewer did not pause fallback game videos

This commit is contained in:
Leon Styhre 2023-08-13 15:18:06 +02:00
parent c15aa73de2
commit f2952ecc28

View file

@ -30,6 +30,8 @@ bool MediaViewer::startMediaViewer(FileData* game)
mScreenshotIndex = -1; mScreenshotIndex = -1;
mTitleScreenIndex = -1; mTitleScreenIndex = -1;
ViewController::getInstance()->pauseViewVideos();
mShowMediaTypes = Settings::getInstance()->getBool("MediaViewerShowTypes"); mShowMediaTypes = Settings::getInstance()->getBool("MediaViewerShowTypes");
if (Settings::getInstance()->getString("MediaViewerHelpPrompts") == "disabled") if (Settings::getInstance()->getString("MediaViewerHelpPrompts") == "disabled")
@ -280,7 +282,6 @@ void MediaViewer::playVideo()
return; return;
mDisplayingImage = false; mDisplayingImage = false;
ViewController::getInstance()->pauseViewVideos();
mVideo = std::make_unique<VideoFFmpegComponent>(); mVideo = std::make_unique<VideoFFmpegComponent>();
mVideo->setOrigin(0.5f, 0.5f); mVideo->setOrigin(0.5f, 0.5f);