diff options
Diffstat (limited to 'libs/ardour/ardour')
-rw-r--r-- | libs/ardour/ardour/audioplaylist.h | 2 | ||||
-rw-r--r-- | libs/ardour/ardour/playlist.h | 4 | ||||
-rw-r--r-- | libs/ardour/ardour/playlist_templates.h | 48 |
3 files changed, 3 insertions, 51 deletions
diff --git a/libs/ardour/ardour/audioplaylist.h b/libs/ardour/ardour/audioplaylist.h index b2e36a10f7..1d4118cf83 100644 --- a/libs/ardour/ardour/audioplaylist.h +++ b/libs/ardour/ardour/audioplaylist.h @@ -54,7 +54,7 @@ class AudioPlaylist : public ARDOUR::Playlist sigc::signal<void,boost::shared_ptr<Crossfade> > NewCrossfade; - template<class T> void foreach_crossfade (T *t, void (T::*func)(boost::shared_ptr<Crossfade>)); + void foreach_crossfade (sigc::slot<void, boost::shared_ptr<Crossfade> >); void crossfades_at (nframes_t frame, Crossfades&); bool destroy_region (boost::shared_ptr<Region>); diff --git a/libs/ardour/ardour/playlist.h b/libs/ardour/ardour/playlist.h index 8be95ca74b..1671d685d5 100644 --- a/libs/ardour/ardour/playlist.h +++ b/libs/ardour/ardour/playlist.h @@ -120,8 +120,8 @@ class Playlist : public SessionObject, nframes64_t find_next_transient (nframes64_t position, int dir); - template<class T> void foreach_region (T *t, void (T::*func)(boost::shared_ptr<Region>, void *), void *arg); - template<class T> void foreach_region (T *t, void (T::*func)(boost::shared_ptr<Region>)); + void foreach_region (sigc::slot<void, boost::shared_ptr<Region>, void *>, void *); + void foreach_region (sigc::slot<void, boost::shared_ptr<Region> >); XMLNode& get_state (); int set_state (const XMLNode&); diff --git a/libs/ardour/ardour/playlist_templates.h b/libs/ardour/ardour/playlist_templates.h deleted file mode 100644 index bf072a71c1..0000000000 --- a/libs/ardour/ardour/playlist_templates.h +++ /dev/null @@ -1,48 +0,0 @@ -/* - Copyright (C) 2003 Paul Davis - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 2 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program; if not, write to the Free Software - Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - -*/ - -#ifndef __ardour_playlist_templates_h__ -#define __ardour_playlist_templates_h__ - -namespace ARDOUR { - -template<class T> void AudioPlaylist::foreach_crossfade (T *t, void (T::*func)(boost::shared_ptr<Crossfade>)) { - RegionLock rlock (this, false); - for (Crossfades::iterator i = _crossfades.begin(); i != _crossfades.end(); i++) { - (t->*func) (*i); - } -} - -template<class T> void Playlist::foreach_region (T *t, void (T::*func)(boost::shared_ptr<Region>, void *), void *arg) { - RegionLock rlock (this, false); - for (RegionList::iterator i = regions.begin(); i != regions.end(); i++) { - (t->*func) ((*i), arg); - } - } - -template<class T> void Playlist::foreach_region (T *t, void (T::*func)(boost::shared_ptr<Region>)) { - RegionLock rlock (this, false); - for (RegionList::const_iterator i = regions.begin(); i != regions.end(); i++) { - (t->*func) (*i); - } -} - -} - -#endif /* __ardour_playlist_templates_h__ */ |