From 02918785ba89701fa8546c679ac76ff61ad0c42c Mon Sep 17 00:00:00 2001 From: WarmUpTill Date: Wed, 24 Nov 2021 20:56:18 +0100 Subject: [PATCH] Hide waitForTransition option if waiting for transition The additions to the transition condition to check for target and source scene of a ongoing transition fullfill the same role and this option does not really fit the current scene check anyways. --- src/headers/macro-condition-scene.hpp | 5 ++++- src/macro-condition-scene.cpp | 7 ++++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/src/headers/macro-condition-scene.hpp b/src/headers/macro-condition-scene.hpp index 1d5e8e9b..8e823fca 100644 --- a/src/headers/macro-condition-scene.hpp +++ b/src/headers/macro-condition-scene.hpp @@ -25,7 +25,10 @@ public: return std::make_shared(); } - bool _waitForTransition = false; + // This option is to be removed in a future version and be replaced by + // transition specific conditions + bool _waitForTransition = true; + SceneSelection _scene; SceneType _type; diff --git a/src/macro-condition-scene.cpp b/src/macro-condition-scene.cpp index bdb6a3dc..8e56f0b8 100644 --- a/src/macro-condition-scene.cpp +++ b/src/macro-condition-scene.cpp @@ -158,7 +158,12 @@ void MacroConditionSceneEdit::SetWidgetVisibility() { _scenes->setVisible(_entryData->_type == SceneType::CURRENT || _entryData->_type == SceneType::PREVIOUS); - _waitForTransition->setVisible(_entryData->_type == SceneType::CURRENT); + + // The waitForTransition option shall be slowly faded out over time and + // be replaced by the transition source and target scene checks + _waitForTransition->setVisible(_entryData->_type == + SceneType::CURRENT && + !_entryData->_waitForTransition); } void MacroConditionSceneEdit::UpdateEntryData()