From dea90e3b8bdf8f5bbc9a8f031d95be3425eeb41d Mon Sep 17 00:00:00 2001 From: Fabrice CARUSO Date: Wed, 9 Oct 2019 17:29:17 +0200 Subject: [PATCH] Video ScreenSaver options : OMX still visible on every platform + UI -> Changed defaut on/off switch images. --- .../src/guis/GuiVideoScreensaverOptions.cpp | 11 ++-- resources/off.svg | 60 ++++++++++++++++++- resources/on.svg | 55 ++++++++++++++++- 3 files changed, 118 insertions(+), 8 deletions(-) diff --git a/es-app/src/guis/GuiVideoScreensaverOptions.cpp b/es-app/src/guis/GuiVideoScreensaverOptions.cpp index 4bed3da29..cf61ffcee 100644 --- a/es-app/src/guis/GuiVideoScreensaverOptions.cpp +++ b/es-app/src/guis/GuiVideoScreensaverOptions.cpp @@ -19,13 +19,11 @@ GuiVideoScreensaverOptions::GuiVideoScreensaverOptions(Window* window, const cha PowerSaver::updateTimeouts(); }); -//#ifdef _RPI_ +#ifdef _RPI_ auto ss_omx = std::make_shared(mWindow); ss_omx->setState(Settings::getInstance()->getBool("ScreenSaverOmxPlayer")); addWithLabel(_("USE OMX PLAYER FOR SCREENSAVER"), ss_omx); addSaveFunc([ss_omx, this] { Settings::getInstance()->setBool("ScreenSaverOmxPlayer", ss_omx->getState()); }); -//#endif - ss_omx->setOnChangedCallback([this, ss_omx, window]() { if (Settings::getInstance()->setBool("ScreenSaverOmxPlayer", ss_omx->getState())) @@ -35,7 +33,8 @@ GuiVideoScreensaverOptions::GuiVideoScreensaverOptions(Window* window, const cha pw->pushGui(new GuiVideoScreensaverOptions(pw, _("VIDEO SCREENSAVER").c_str())); } }); - +#endif + // Render Video Game Name as subtitles auto ss_info = std::make_shared< OptionListComponent >(mWindow, _("SHOW GAME INFO"), false); std::vector info_type; @@ -49,9 +48,9 @@ GuiVideoScreensaverOptions::GuiVideoScreensaverOptions(Window* window, const cha bool advancedOptions = true; -//#ifdef _RPI_ +#ifdef _RPI_ advancedOptions = !Settings::getInstance()->getBool("ScreenSaverOmxPlayer"); -//#endif +#endif if (advancedOptions) { diff --git a/resources/off.svg b/resources/off.svg index 0f6c8a8b8..5a293cd40 100644 --- a/resources/off.svg +++ b/resources/off.svg @@ -1 +1,59 @@ - \ No newline at end of file + + + + + + image/svg+xml + + + + + + + + + diff --git a/resources/on.svg b/resources/on.svg index 01702df8f..726d7bf46 100644 --- a/resources/on.svg +++ b/resources/on.svg @@ -1 +1,54 @@ - \ No newline at end of file + + + + + + image/svg+xml + + + + + + + +