diff options
Diffstat (limited to 'libs/ardour/session_state.cc')
-rw-r--r-- | libs/ardour/session_state.cc | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/libs/ardour/session_state.cc b/libs/ardour/session_state.cc index 581d6950c5..b7fac84ffe 100644 --- a/libs/ardour/session_state.cc +++ b/libs/ardour/session_state.cc @@ -114,6 +114,7 @@ #include "ardour/revision.h" #include "ardour/route_group.h" #include "ardour/send.h" +#include "ardour/selection.h" #include "ardour/session.h" #include "ardour/session_directory.h" #include "ardour/session_metadata.h" @@ -1286,6 +1287,8 @@ Session::state (bool full_state) if (full_state) { + node->add_child_nocopy (_selection->get_state()); + if (_locations) { node->add_child_nocopy (_locations->get_state()); } @@ -1649,6 +1652,10 @@ Session::set_state (const XMLNode& node, int version) } } + if ((child = find_named_node (node, X_("Selection")))) { + _selection->set_state (*child, version); + } + update_route_record_state (); /* here beginneth the second phase ... */ @@ -3583,6 +3590,12 @@ Session::controllable_by_id (const PBD::ID& id) return boost::shared_ptr<Controllable>(); } +boost::shared_ptr<AutomationControl> +Session::automation_control_by_id (const PBD::ID& id) +{ + return boost::dynamic_pointer_cast<AutomationControl> (controllable_by_id (id)); +} + boost::shared_ptr<Controllable> Session::controllable_by_descriptor (const ControllableDescriptor& desc) { |