Sort session routes before trying to do the group tabs
[ardour.git] / libs / ardour / playlist.cc
index 66a0eab9ad0a9355fdbde8f6a2566303d7416b4d..3bc5f57577d7349d0647880245adf7d05dfd67d9 100644 (file)
@@ -185,7 +185,6 @@ Playlist::Playlist (boost::shared_ptr<const Playlist> other, string namestr, boo
        in_flush = false;
        in_partition = false;
        subcnt = 0;
-       _read_data_count = 0;
        _frozen = other->_frozen;
 
        layer_op_counter = other->layer_op_counter;
@@ -319,7 +318,6 @@ Playlist::init (bool hide)
        in_flush = false;
        in_partition = false;
        subcnt = 0;
-       _read_data_count = 0;
        _frozen = false;
        layer_op_counter = 0;
        freeze_length = 0;
@@ -848,7 +846,6 @@ Playlist::flush_notifications (bool from_undo)
  {
         RegionList::iterator i;
         framecnt_t old_length = 0;
-        int ret = -1;
 
         if (!holding_state()) {
                 old_length = _get_extent().second;
@@ -881,7 +878,6 @@ Playlist::flush_notifications (bool from_undo)
                         }
 
                         notify_region_removed (region);
-                        ret = 0;
                         break;
                 }
         }
@@ -2215,6 +2211,8 @@ Playlist::flush_notifications (bool from_undo)
 
         plist = node.properties();
 
+        set_id (node);
+
         for (piter = plist.begin(); piter != plist.end(); ++piter) {
 
                 prop = *piter;
@@ -2222,8 +2220,6 @@ Playlist::flush_notifications (bool from_undo)
                 if (prop->name() == X_("name")) {
                         _name = prop->value();
                         _set_sort_id ();
-                } else if (prop->name() == X_("id")) {
-                        _id = prop->value();
                 } else if (prop->name() == X_("orig-diskstream-id")) {
                         _orig_diskstream_id = prop->value ();
                 } else if (prop->name() == X_("frozen")) {