diff --git a/es-app/src/views/GamelistView.cpp b/es-app/src/views/GamelistView.cpp index c16d632b9..c70db67c4 100644 --- a/es-app/src/views/GamelistView.cpp +++ b/es-app/src/views/GamelistView.cpp @@ -205,10 +205,17 @@ void GamelistView::update(int deltaTime) } for (auto& video : mVideoComponents) { - if (!mVideoPlaying) - video->onHide(); - else if (mVideoPlaying && !video->isVideoPaused() && !mWindow->isScreensaverActive()) + if (!mVideoPlaying) { + if (!video->getScrollHide()) + video->onHide(); + else if (!video->hasStaticImage()) + video->onHide(); + else if (video->getOpacity() == 0) + video->onHide(); + } + else if (mVideoPlaying && !video->isVideoPaused() && !mWindow->isScreensaverActive()) { video->onShow(); + } if (ViewController::getInstance()->getGameLaunchTriggered() && video->isAnimationPlaying(0)) video->finishAnimation(0); @@ -733,6 +740,10 @@ void GamelistView::updateInfoPanel() if (image->getScrollHide()) comps.emplace_back(image.get()); } + for (auto& video : mVideoComponents) { + if (video->getScrollHide()) + comps.emplace_back(video.get()); + } for (auto& badge : mBadgeComponents) { if (badge->getScrollHide()) comps.emplace_back(badge.get()); diff --git a/es-core/src/components/VideoComponent.h b/es-core/src/components/VideoComponent.h index a12ab2eb3..f18d5522b 100644 --- a/es-core/src/components/VideoComponent.h +++ b/es-core/src/components/VideoComponent.h @@ -49,6 +49,7 @@ public: void setOpacity(unsigned char opacity) override { mOpacity = opacity; } bool hasStaticVideo() { return !mConfig.staticVideoPath.empty(); } + bool hasStaticImage() { return mStaticImage.getTextureSize() != glm::ivec2 {0, 0}; } void onShow() override; void onHide() override;