mirror of
https://github.com/WarmUpTill/SceneSwitcher.git
synced 2026-08-12 20:28:11 -05:00
Resolve variables in log messages
This commit is contained in:
@@ -102,8 +102,8 @@ void MacroActionSceneOrder::LogAction() const
|
||||
if (it != actionTypes.end()) {
|
||||
vblog(LOG_INFO,
|
||||
"performed order action \"%s\" for source \"%s\" on scene \"%s\"",
|
||||
it->second.c_str(), _source.ToString().c_str(),
|
||||
_scene.ToString().c_str());
|
||||
it->second.c_str(), _source.ToString(true).c_str(),
|
||||
_scene.ToString(true).c_str());
|
||||
} else {
|
||||
blog(LOG_WARNING, "ignored unknown scene order action %d",
|
||||
static_cast<int>(_action));
|
||||
|
||||
@@ -125,11 +125,11 @@ void MacroActionSwitchScene::LogAction() const
|
||||
switch (t) {
|
||||
case SceneSelection::Type::SCENE:
|
||||
vblog(LOG_INFO, "switch to scene '%s'",
|
||||
_scene.ToString().c_str());
|
||||
_scene.ToString(true).c_str());
|
||||
break;
|
||||
case SceneSelection::Type::GROUP:
|
||||
vblog(LOG_INFO, "switch to scene '%s' (scene group '%s')",
|
||||
sceneName.c_str(), _scene.ToString().c_str());
|
||||
sceneName.c_str(), _scene.ToString(true).c_str());
|
||||
break;
|
||||
case SceneSelection::Type::PREVIOUS:
|
||||
vblog(LOG_INFO, "switch to previous scene '%s'",
|
||||
|
||||
@@ -30,7 +30,7 @@ void MacroActionSceneTransform::LogAction() const
|
||||
{
|
||||
vblog(LOG_INFO,
|
||||
"performed transform action for source \"%s\" on scene \"%s\"",
|
||||
_source.ToString().c_str(), _scene.ToString().c_str());
|
||||
_source.ToString(true).c_str(), _scene.ToString(true).c_str());
|
||||
}
|
||||
|
||||
bool MacroActionSceneTransform::Save(obs_data_t *obj) const
|
||||
|
||||
@@ -99,13 +99,14 @@ void MacroActionSceneVisibility::LogAction() const
|
||||
if (_sourceType == SceneItemSourceType::SOURCE) {
|
||||
vblog(LOG_INFO,
|
||||
"performed visibility action \"%s\" for source \"%s\" on scene \"%s\"",
|
||||
it->second.c_str(), _source.ToString().c_str(),
|
||||
_scene.ToString().c_str());
|
||||
it->second.c_str(),
|
||||
_source.ToString(true).c_str(),
|
||||
_scene.ToString(true).c_str());
|
||||
} else {
|
||||
vblog(LOG_INFO,
|
||||
"performed visibility action \"%s\" for any source type \"%s\" on scene \"%s\"",
|
||||
it->second.c_str(), _sourceGroup.c_str(),
|
||||
_scene.ToString().c_str());
|
||||
_scene.ToString(true).c_str());
|
||||
}
|
||||
} else {
|
||||
blog(LOG_WARNING, "ignored unknown SceneVisibility action %d",
|
||||
|
||||
@@ -64,7 +64,7 @@ void MacroActionScreenshot::LogAction() const
|
||||
vblog(LOG_INFO, "trigger screenshot for \"%s\"",
|
||||
_targetType == TargetType::SOURCE
|
||||
? GetWeakSourceName(_source).c_str()
|
||||
: _scene.ToString().c_str());
|
||||
: _scene.ToString(true).c_str());
|
||||
}
|
||||
|
||||
bool MacroActionScreenshot::Save(obs_data_t *obj) const
|
||||
|
||||
@@ -77,7 +77,7 @@ void MacroActionSudioMode::LogAction() const
|
||||
auto it = actionTypes.find(_action);
|
||||
if (it != actionTypes.end()) {
|
||||
vblog(LOG_INFO, "performed action \"%s\" with scene \"%s\"",
|
||||
it->second.c_str(), _scene.ToString().c_str());
|
||||
it->second.c_str(), _scene.ToString(true).c_str());
|
||||
} else {
|
||||
blog(LOG_WARNING, "ignored unknown studio mode action %d",
|
||||
static_cast<int>(_action));
|
||||
|
||||
@@ -127,18 +127,18 @@ void MacroActionTransition::LogAction() const
|
||||
msgBegin += "set scene transition";
|
||||
break;
|
||||
case Type::SCENE_OVERRIDE:
|
||||
msgBegin +=
|
||||
"set scene override transition of " + _scene.ToString();
|
||||
msgBegin += "set scene override transition of " +
|
||||
_scene.ToString(true);
|
||||
break;
|
||||
case Type::SOURCE_SHOW:
|
||||
msgBegin += "set source show transition of " +
|
||||
_source.ToString() + " on scene " +
|
||||
_scene.ToString();
|
||||
_source.ToString(true) + " on scene " +
|
||||
_scene.ToString(true);
|
||||
break;
|
||||
case Type::SOURCE_HIDE:
|
||||
msgBegin += "set source hide transition of " +
|
||||
_source.ToString() + " on scene " +
|
||||
_scene.ToString();
|
||||
_source.ToString(true) + " on scene " +
|
||||
_scene.ToString(true);
|
||||
break;
|
||||
}
|
||||
if (_setDuration) {
|
||||
|
||||
Reference in New Issue
Block a user