Fix track-header visibility for inactive tracks
This supersedes 0708cdb6b4, an explicit `name_label.show()`
is not needed. The inactive label was missing an explicit call
to show.
This also fixes MIDI track MIDNAM Selector visibility
This commit is contained in:
@@ -296,7 +296,6 @@ AudioTimeAxisView::route_active_changed ()
|
||||
controls_table.hide();
|
||||
inactive_table.show();
|
||||
RouteTimeAxisView::hide_all_automation();
|
||||
name_label.show();
|
||||
} else {
|
||||
inactive_table.hide();
|
||||
controls_table.show();
|
||||
|
||||
@@ -558,9 +558,24 @@ MidiTimeAxisView::midi_view()
|
||||
return dynamic_cast<MidiStreamView*>(_view);
|
||||
}
|
||||
|
||||
void
|
||||
MidiTimeAxisView::update_midi_controls_visibility (uint32_t h)
|
||||
{
|
||||
if (_route && !_route->active ()) {
|
||||
h = 0;
|
||||
}
|
||||
if (h >= MIDI_CONTROLS_BOX_MIN_HEIGHT) {
|
||||
_midi_controls_box.show ();
|
||||
} else {
|
||||
_midi_controls_box.hide();
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
MidiTimeAxisView::set_height (uint32_t h, TrackHeightMode m)
|
||||
{
|
||||
update_midi_controls_visibility (h);
|
||||
|
||||
if (h >= MIDI_CONTROLS_BOX_MIN_HEIGHT) {
|
||||
_midi_controls_box.show ();
|
||||
} else {
|
||||
@@ -1356,10 +1371,11 @@ MidiTimeAxisView::route_active_changed ()
|
||||
{
|
||||
RouteTimeAxisView::route_active_changed ();
|
||||
update_control_names();
|
||||
update_midi_controls_visibility (height);
|
||||
|
||||
if (!_route->active()) {
|
||||
controls_table.hide();
|
||||
inactive_table.show_all();
|
||||
inactive_table.show();
|
||||
RouteTimeAxisView::hide_all_automation();
|
||||
} else {
|
||||
inactive_table.hide();
|
||||
|
||||
@@ -142,6 +142,7 @@ private:
|
||||
void contents_height_changed ();
|
||||
|
||||
void update_control_names ();
|
||||
void update_midi_controls_visibility (uint32_t);
|
||||
|
||||
bool _ignore_signals;
|
||||
std::string _effective_model;
|
||||
|
||||
@@ -175,6 +175,7 @@ TimeAxisView::TimeAxisView (ARDOUR::Session* sess, PublicEditor& ed, TimeAxisVie
|
||||
name_label.set_size_request(name_width_px, -1);
|
||||
|
||||
name_label.show ();
|
||||
inactive_label.show ();
|
||||
|
||||
controls_table.set_row_spacings (2);
|
||||
controls_table.set_col_spacings (2);
|
||||
|
||||
Reference in New Issue
Block a user