summaryrefslogtreecommitdiff
path: root/gtk2_ardour/editor.cc
diff options
context:
space:
mode:
authorRobin Gareus <robin@gareus.org>2017-01-13 08:43:18 +0100
committerRobin Gareus <robin@gareus.org>2017-01-13 08:43:18 +0100
commit058f1cf9e13ab07e8c68ae9ee6fcc8d8436ff0ae (patch)
tree9eaa97544d70c28937b0a67a7666194aaf1a14b6 /gtk2_ardour/editor.cc
parent7841a756182693fa15541d58ef5bf57c36199471 (diff)
Fix editor-mixer update when deleting a Route before a VCA
When deleting the last track before a VCA, on-delete the editor-mixer switches to display the next TAV. If that turns out to be a VCATAV, the editor-mixer will ignore it and keep displaying the deleted route, holding a shared pointer reference (ports won't be dropped, etc etc).
Diffstat (limited to 'gtk2_ardour/editor.cc')
-rw-r--r--gtk2_ardour/editor.cc10
1 files changed, 10 insertions, 0 deletions
diff --git a/gtk2_ardour/editor.cc b/gtk2_ardour/editor.cc
index 17ed10e68d..d7e65a13cc 100644
--- a/gtk2_ardour/editor.cc
+++ b/gtk2_ardour/editor.cc
@@ -5400,6 +5400,16 @@ Editor::timeaxisview_deleted (TimeAxisView *tv)
next_tv = (*i);
}
+ // skip VCAs (cannot be selected, n/a in editor-mixer)
+ if (dynamic_cast<VCATimeAxisView*> (next_tv)) {
+ /* VCAs are sorted last in line -- route_sorter.h, jump to top */
+ next_tv = track_views.front();
+ }
+ if (dynamic_cast<VCATimeAxisView*> (next_tv)) {
+ /* just in case: no master, only a VCA remains */
+ next_tv = 0;
+ }
+
if (next_tv) {
set_selected_mixer_strip (*next_tv);