diff options
author | Sampo Savolainen <v2@iki.fi> | 2008-02-09 10:32:45 +0000 |
---|---|---|
committer | Sampo Savolainen <v2@iki.fi> | 2008-02-09 10:32:45 +0000 |
commit | 3ee550573c2ae3e37d0e3bd7eedb6c64e13c3ebc (patch) | |
tree | 58f18ba3dab0d7dd95f3c8cbbefc0451b0996328 /libs/ardour/route.cc | |
parent | 22c05e56a6a3a0d3e8a56185e004b1550fbdba08 (diff) |
Make sure buses and tracks have unique names.
git-svn-id: svn://localhost/ardour2/branches/2.0-ongoing@3033 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/route.cc')
-rw-r--r-- | libs/ardour/route.cc | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/libs/ardour/route.cc b/libs/ardour/route.cc index f1953af386..95571bd3da 100644 --- a/libs/ardour/route.cc +++ b/libs/ardour/route.cc @@ -184,6 +184,20 @@ Route::sync_order_keys () } } +string +Route::ensure_track_or_route_name(string name, Session &session) +{ + string newname = name; + + while (session.route_by_name (newname)!=NULL) + { + newname = bump_name_once (newname); + } + + return newname; +} + + void Route::inc_gain (gain_t fraction, void *src) { |