mirror of
https://github.com/WarmUpTill/SceneSwitcher.git
synced 2026-08-15 22:04:17 -05:00
Add support to resolve variables on action queue add
This commit is contained in:
@@ -38,6 +38,16 @@ static const std::map<MacroActionMedia::SelectionType, std::string>
|
||||
"AdvSceneSwitcher.action.media.selectionType.sceneItem"},
|
||||
};
|
||||
|
||||
std::shared_ptr<MacroAction> MacroActionMedia::Create(Macro *m)
|
||||
{
|
||||
return std::make_shared<MacroActionMedia>(m);
|
||||
}
|
||||
|
||||
std::shared_ptr<MacroAction> MacroActionMedia::Copy() const
|
||||
{
|
||||
return std::make_shared<MacroActionMedia>(*this);
|
||||
}
|
||||
|
||||
std::string MacroActionMedia::GetShortDesc() const
|
||||
{
|
||||
if (_selection == SelectionType::SOURCE) {
|
||||
@@ -150,6 +160,15 @@ bool MacroActionMedia::Load(obs_data_t *obj)
|
||||
return true;
|
||||
}
|
||||
|
||||
void MacroActionMedia::ResolveVariablesToFixedValues()
|
||||
{
|
||||
_seekDuration.ResolveVariables();
|
||||
_seekPercentage.ResolveVariables();
|
||||
_mediaSource.ResolveVariables();
|
||||
_sceneItem.ResolveVariables();
|
||||
_scene.ResolveVariables();
|
||||
}
|
||||
|
||||
static inline void populateActionSelection(QComboBox *list)
|
||||
{
|
||||
for (const auto &[_, name] : actionTypes) {
|
||||
|
||||
Reference in New Issue
Block a user