summaryrefslogtreecommitdiff
path: root/libs/ardour/route.cc
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2016-07-20 14:47:14 -0400
committerPaul Davis <paul@linuxaudiosystems.com>2016-07-20 14:47:24 -0400
commit316562ee9e04edccff6de5f97618cbd59ef12755 (patch)
treece44d6ef06a551a11de0d05faa0b483e99ba759b /libs/ardour/route.cc
parentb502d689e29183595505c1b1180298d2f11158dc (diff)
ensure that Route::_phase_control has its state restored, and also re-arrange Route::set_state() to avoid duplicated control set_state() calls
Diffstat (limited to 'libs/ardour/route.cc')
-rw-r--r--libs/ardour/route.cc35
1 files changed, 15 insertions, 20 deletions
diff --git a/libs/ardour/route.cc b/libs/ardour/route.cc
index f1bf1127c4..d072d81c88 100644
--- a/libs/ardour/route.cc
+++ b/libs/ardour/route.cc
@@ -2394,22 +2394,6 @@ Route::set_state (const XMLNode& node, int version)
} else {
warning << string_compose (_("Pannable state found for route (%1) without a panner!"), name()) << endmsg;
}
- } else if (child->name() == Controllable::xml_node_name) {
- if ((prop = child->property (X_("name"))) == 0) {
- continue;
- }
-
- if (prop->value() == _gain_control->name()) {
- _gain_control->set_state (*child, version);
- } else if (prop->value() == _solo_control->name()) {
- _solo_control->set_state (*child, version);
- } else if (prop->value() == _solo_safe_control->name()) {
- _solo_safe_control->set_state (*child, version);
- } else if (prop->value() == _solo_isolate_control->name()) {
- _solo_isolate_control->set_state (*child, version);
- } else if (prop->value() == _solo_control->name()) {
- _mute_control->set_state (*child, version);
- }
} else if (child->name() == Slavable::xml_node_name) {
Slavable::set_state (*child, version);
}
@@ -2467,13 +2451,24 @@ Route::set_state (const XMLNode& node, int version)
XMLNode *cmt = *(child->children().begin());
_comment = cmt->content();
- } else if (child->name() == Controllable::xml_node_name && (prop = child->property("name")) != 0) {
- if (prop->value() == "solo") {
+ } else if (child->name() == Controllable::xml_node_name) {
+ if ((prop = child->property (X_("name"))) == 0) {
+ continue;
+ }
+
+ if (prop->value() == _gain_control->name()) {
+ _gain_control->set_state (*child, version);
+ } else if (prop->value() == _solo_control->name()) {
_solo_control->set_state (*child, version);
- } else if (prop->value() == "mute") {
+ } else if (prop->value() == _solo_safe_control->name()) {
+ _solo_safe_control->set_state (*child, version);
+ } else if (prop->value() == _solo_isolate_control->name()) {
+ _solo_isolate_control->set_state (*child, version);
+ } else if (prop->value() == _solo_control->name()) {
_mute_control->set_state (*child, version);
+ } else if (prop->value() == _phase_control->name()) {
+ _phase_control->set_state (*child, version);
}
-
} else if (child->name() == MuteMaster::xml_node_name) {
_mute_master->set_state (*child, version);