diff options
author | Robin Gareus <robin@gareus.org> | 2013-07-09 01:25:54 +0200 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2013-07-10 15:27:14 +0200 |
commit | 24f2961cce98f296ef6c1824cce86c241bb120e6 (patch) | |
tree | 59ec591011a23548d39c321880cac3047247b4f3 /libs/ardour/route.cc | |
parent | 4d49961c93fe23dc4f76a5bcb60c93d0c80bcd3c (diff) |
...towards unique track numbers.
Diffstat (limited to 'libs/ardour/route.cc')
-rw-r--r-- | libs/ardour/route.cc | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/libs/ardour/route.cc b/libs/ardour/route.cc index e87cb4b03f..9d121f6055 100644 --- a/libs/ardour/route.cc +++ b/libs/ardour/route.cc @@ -88,6 +88,7 @@ Route::Route (Session& sess, string name, Flag flg, DataType default_type) , _soloed_by_others_upstream (0) , _soloed_by_others_downstream (0) , _solo_isolated (0) + , _unique_id (0) , _denormal_protection (false) , _recordable (true) , _silent (false) @@ -1881,6 +1882,9 @@ Route::state(bool full_state) node->add_property("meter-type", enum_2_string (_meter_type)); + snprintf (buf, sizeof (buf), "%d", _unique_id); + node->add_property("unique-id", buf); + if (_route_group) { node->add_property("route-group", _route_group->name()); } @@ -2059,6 +2063,10 @@ Route::set_state (const XMLNode& node, int version) _meter_type = MeterType (string_2_enum (prop->value (), _meter_type)); } + if ((prop = node.property (X_("unique-id"))) != 0) { + _unique_id = atoi(prop->value()); + } + set_processor_state (processor_state); // this looks up the internal instrument in processors |