diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2007-03-21 02:39:12 +0000 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2007-03-21 02:39:12 +0000 |
commit | 767984b486086e3682e521179c2fb8364b3bba76 (patch) | |
tree | 3a03250848c776c0edf0de4df4a3d89397711c21 /libs/ardour/playlist.cc | |
parent | 6525aaeb70ed7dcaf068e641dc04b4f7c5ba61e4 (diff) |
probably fix cleanup issues, but testing required
git-svn-id: svn://localhost/ardour2/trunk@1632 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/playlist.cc')
-rw-r--r-- | libs/ardour/playlist.cc | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/libs/ardour/playlist.cc b/libs/ardour/playlist.cc index 496be33950..ae9e23fcc9 100644 --- a/libs/ardour/playlist.cc +++ b/libs/ardour/playlist.cc @@ -574,6 +574,11 @@ Playlist::remove_region_internal (boost::shared_ptr<Region>region) old_length = _get_maximum_extent(); } + if (!in_set_state) { + /* unset playlist */ + region->set_playlist (boost::weak_ptr<Playlist>()); + } + for (i = regions.begin(); i != regions.end(); ++i) { if (*i == region) { @@ -1175,6 +1180,14 @@ Playlist::region_changed (Change what_changed, boost::shared_ptr<Region> region) } void +Playlist::drop_regions () +{ + RegionLock rl (this); + regions.clear (); + all_regions.clear (); +} + +void Playlist::clear (bool with_signals) { { |