persist remote_control_id for busses
git-svn-id: svn://localhost/ardour2/trunk@1470 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
@@ -276,14 +276,7 @@ AudioTrack::_set_state (const XMLNode& node, bool call_base)
|
||||
for (niter = nlist.begin(); niter != nlist.end(); ++niter){
|
||||
child = *niter;
|
||||
|
||||
if (child->name() == X_("remote_control")) {
|
||||
if ((prop = child->property (X_("id"))) != 0) {
|
||||
int32_t x;
|
||||
sscanf (prop->value().c_str(), "%d", &x);
|
||||
set_remote_control_id (x);
|
||||
}
|
||||
|
||||
} else if (child->name() == X_("recenable")) {
|
||||
if (child->name() == X_("recenable")) {
|
||||
_rec_enable_control.set_state (*child);
|
||||
_session.add_controllable (&_rec_enable_control);
|
||||
}
|
||||
@@ -329,11 +322,6 @@ AudioTrack::state(bool full_state)
|
||||
align_node->add_property (X_("style"), enum_2_string (as));
|
||||
root.add_child_nocopy (*align_node);
|
||||
|
||||
XMLNode* remote_control_node = new XMLNode (X_("remote_control"));
|
||||
snprintf (buf, sizeof (buf), "%d", _remote_control_id);
|
||||
remote_control_node->add_property (X_("id"), buf);
|
||||
root.add_child_nocopy (*remote_control_node);
|
||||
|
||||
root.add_property (X_("mode"), enum_2_string (_mode));
|
||||
|
||||
/* we don't return diskstream state because we don't
|
||||
|
||||
@@ -1421,6 +1421,11 @@ Route::state(bool full_state)
|
||||
node->add_child_nocopy (_solo_control.get_state ());
|
||||
node->add_child_nocopy (_mute_control.get_state ());
|
||||
|
||||
XMLNode* remote_control_node = new XMLNode (X_("remote_control"));
|
||||
snprintf (buf, sizeof (buf), "%d", _remote_control_id);
|
||||
remote_control_node->add_property (X_("id"), buf);
|
||||
node->add_child_nocopy (*remote_control_node);
|
||||
|
||||
if (_control_outs) {
|
||||
XMLNode* cnode = new XMLNode (X_("ControlOuts"));
|
||||
cnode->add_child_nocopy (_control_outs->state (full_state));
|
||||
@@ -1714,6 +1719,13 @@ Route::_set_state (const XMLNode& node, bool call_base)
|
||||
_session.add_controllable (&_mute_control);
|
||||
}
|
||||
}
|
||||
else if (child->name() == X_("remote_control")) {
|
||||
if ((prop = child->property (X_("id"))) != 0) {
|
||||
int32_t x;
|
||||
sscanf (prop->value().c_str(), "%d", &x);
|
||||
set_remote_control_id (x);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if ((prop = node.property (X_("mix-group"))) != 0) {
|
||||
|
||||
Reference in New Issue
Block a user