diff options
author | Robin Gareus <robin@gareus.org> | 2016-09-23 20:34:28 +0200 |
---|---|---|
committer | Robin Gareus <robin@gareus.org> | 2016-09-23 20:34:28 +0200 |
commit | 8018bed0ded65003279dfbdf446bae2697378488 (patch) | |
tree | 00f5148ce33e6af3737596b64b8e89269926d794 /libs/ardour/session_playlists.cc | |
parent | f7cb5b1a6b26cd13868c6b379760d545097118d9 (diff) |
add an option to exclude unused Audio Sources when archiving the session
Diffstat (limited to 'libs/ardour/session_playlists.cc')
-rw-r--r-- | libs/ardour/session_playlists.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/libs/ardour/session_playlists.cc b/libs/ardour/session_playlists.cc index 95982b6158..5713e15458 100644 --- a/libs/ardour/session_playlists.cc +++ b/libs/ardour/session_playlists.cc @@ -505,7 +505,7 @@ SessionPlaylists::playlists_for_track (boost::shared_ptr<Track> tr) const } void -SessionPlaylists::foreach (boost::function<void(boost::shared_ptr<const Playlist>)> functor) +SessionPlaylists::foreach (boost::function<void(boost::shared_ptr<const Playlist>)> functor, bool incl_unused) { Glib::Threads::Mutex::Lock lm (lock); for (List::iterator i = playlists.begin(); i != playlists.end(); i++) { @@ -513,6 +513,9 @@ SessionPlaylists::foreach (boost::function<void(boost::shared_ptr<const Playlist functor (*i); } } + if (!incl_unused) { + return; + } for (List::iterator i = unused_playlists.begin(); i != unused_playlists.end(); i++) { if (!(*i)->hidden()) { functor (*i); |