Keep track/bus number visible when disabling track

This commit is contained in:
Robin Gareus
2020-01-22 01:45:18 +01:00
parent 6914671736
commit 81c3bf175a
2 changed files with 7 additions and 3 deletions

View File

@@ -447,10 +447,12 @@ RouteTimeAxisView::update_track_number_visibility ()
}
if (number_label.get_parent()) {
controls_table.remove (number_label);
number_label.get_parent()->remove (number_label);
}
if (show_label) {
if (ARDOUR::Profile->get_mixbus()) {
if (!_route->active()) {
inactive_table.attach (number_label, 0, 1, 0, 1, Gtk::SHRINK, Gtk::EXPAND|Gtk::FILL, 1, 0);
} else if (ARDOUR::Profile->get_mixbus()) {
controls_table.attach (number_label, 3, 4, 0, 1, Gtk::SHRINK, Gtk::EXPAND|Gtk::FILL, 1, 0);
} else {
controls_table.attach (number_label, 0, 1, 0, 1, Gtk::SHRINK, Gtk::EXPAND|Gtk::FILL, 1, 0);
@@ -470,6 +472,8 @@ RouteTimeAxisView::update_track_number_visibility ()
void
RouteTimeAxisView::route_active_changed ()
{
RouteUI::route_active_changed ();
update_track_number_visibility ();
}
void

View File

@@ -190,7 +190,7 @@ TimeAxisView::TimeAxisView (ARDOUR::Session* sess, PublicEditor& ed, TimeAxisVie
controls_table.set_no_show_all ();
inactive_table.set_border_width (4); //try to match the offset of the label on an "active" track
inactive_table.attach (inactive_label, 0, 1, 0, 1, Gtk::FILL|Gtk::EXPAND, Gtk::SHRINK, 0, 0);
inactive_table.attach (inactive_label, 1, 2, 0, 1, Gtk::FILL|Gtk::EXPAND, Gtk::SHRINK, 0, 0);
controls_vbox.pack_start (inactive_table, false, false);
controls_vbox.pack_start (controls_table, false, false);