mirror of
https://github.com/WarmUpTill/SceneSwitcher.git
synced 2026-03-24 10:55:10 -05:00
The intention of this change is to reduce the interdependency of the various components to reduce compile time when applying changes.
53 lines
925 B
C++
53 lines
925 B
C++
#include "macro-action.hpp"
|
|
|
|
namespace advss {
|
|
|
|
MacroAction::MacroAction(Macro *m, bool supportsVariableValue)
|
|
: MacroSegment(m, supportsVariableValue)
|
|
{
|
|
}
|
|
|
|
bool MacroAction::Save(obs_data_t *obj) const
|
|
{
|
|
MacroSegment::Save(obj);
|
|
obs_data_set_string(obj, "id", GetId().c_str());
|
|
return true;
|
|
}
|
|
|
|
bool MacroAction::Load(obs_data_t *obj)
|
|
{
|
|
MacroSegment::Load(obj);
|
|
return true;
|
|
}
|
|
|
|
void MacroAction::LogAction() const
|
|
{
|
|
vblog(LOG_INFO, "performed action %s", GetId().c_str());
|
|
}
|
|
|
|
MacroRefAction::MacroRefAction(Macro *m, bool supportsVariableValue)
|
|
: MacroAction(m, supportsVariableValue)
|
|
{
|
|
}
|
|
|
|
bool MacroRefAction::PostLoad()
|
|
{
|
|
_macro.PostLoad();
|
|
return true;
|
|
}
|
|
|
|
MultiMacroRefAction::MultiMacroRefAction(Macro *m, bool supportsVariableValue)
|
|
: MacroAction(m, supportsVariableValue)
|
|
{
|
|
}
|
|
|
|
bool MultiMacroRefAction::PostLoad()
|
|
{
|
|
for (auto ¯o : _macros) {
|
|
macro.PostLoad();
|
|
}
|
|
return true;
|
|
}
|
|
|
|
} // namespace advss
|