summaryrefslogtreecommitdiff
path: root/libs/ardour/control_protocol_manager.cc
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2013-01-06 14:39:27 +0000
committerPaul Davis <paul@linuxaudiosystems.com>2013-01-06 14:39:27 +0000
commit397729eb182ba3d5e311f0ac80959cf72f5cba24 (patch)
tree319e5d7d755fa23b8672667b717c6c65416888ab /libs/ardour/control_protocol_manager.cc
parenta401abfee715529d2379f7d0fef5068bddc06640 (diff)
fix continuing SNAFUs with ::set_state() for control protocols and the parent/child/grandchild relationship for the XML nodes. this corrects problems with MackieControl
git-svn-id: svn://localhost/ardour2/branches/3.0@13794 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/control_protocol_manager.cc')
-rw-r--r--libs/ardour/control_protocol_manager.cc8
1 files changed, 2 insertions, 6 deletions
diff --git a/libs/ardour/control_protocol_manager.cc b/libs/ardour/control_protocol_manager.cc
index 64876b1d5f..0fd5319e40 100644
--- a/libs/ardour/control_protocol_manager.cc
+++ b/libs/ardour/control_protocol_manager.cc
@@ -72,6 +72,7 @@ ControlProtocolManager::set_session (Session* s)
for (list<ControlProtocolInfo*>::iterator i = control_protocol_info.begin(); i != control_protocol_info.end(); ++i) {
if ((*i)->requested || (*i)->mandatory) {
+
instantiate (**i);
(*i)->requested = false;
@@ -344,12 +345,7 @@ ControlProtocolManager::set_state (const XMLNode& node, int /*version*/)
ControlProtocolInfo* cpi = cpi_by_name (prop->value());
if (cpi) {
-
- if (!(*citer)->children().empty()) {
- cpi->state = new XMLNode (*((*citer)->children().front ()));
- } else {
- cpi->state = 0;
- }
+ cpi->state = new XMLNode (**citer);
if (active) {
if (_session) {