mirror of
https://github.com/WarmUpTill/SceneSwitcher.git
synced 2026-03-22 01:44:49 -05:00
Enable getting variable values from idle condition
This commit is contained in:
parent
3d4b69848c
commit
ae6f0bc470
|
|
@ -12,7 +12,9 @@ bool MacroConditionIdle::_registered = MacroConditionFactory::Register(
|
|||
|
||||
bool MacroConditionIdle::CheckCondition()
|
||||
{
|
||||
return secondsSinceLastInput() >= _duration.seconds;
|
||||
auto seconds = secondsSinceLastInput();
|
||||
SetVariableValue(std::to_string(seconds));
|
||||
return seconds >= _duration.seconds;
|
||||
}
|
||||
|
||||
bool MacroConditionIdle::Save(obs_data_t *obj) const
|
||||
|
|
|
|||
|
|
@ -7,7 +7,7 @@
|
|||
|
||||
class MacroConditionIdle : public MacroCondition {
|
||||
public:
|
||||
MacroConditionIdle(Macro *m) : MacroCondition(m) {}
|
||||
MacroConditionIdle(Macro *m) : MacroCondition(m, true) {}
|
||||
bool CheckCondition();
|
||||
bool Save(obs_data_t *obj) const;
|
||||
bool Load(obs_data_t *obj);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user