diff options
author | Ben Loftis <ben@harrisonconsoles.com> | 2016-12-12 12:16:43 -0600 |
---|---|---|
committer | Ben Loftis <ben@harrisonconsoles.com> | 2016-12-12 12:16:43 -0600 |
commit | afa6720288fce4513dc16c9cb53562c051172c52 (patch) | |
tree | 9377516cd60e3184cff78fa0bda0c30c2994fe58 /gtk2_ardour/mixer_strip.cc | |
parent | e9deb82ef6449829d5d645a5fd4b454b945d7937 (diff) |
UI tweak for the spacer at the bottom of the master bus.
Diffstat (limited to 'gtk2_ardour/mixer_strip.cc')
-rw-r--r-- | gtk2_ardour/mixer_strip.cc | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/gtk2_ardour/mixer_strip.cc b/gtk2_ardour/mixer_strip.cc index ca1b104e0f..9adb670924 100644 --- a/gtk2_ardour/mixer_strip.cc +++ b/gtk2_ardour/mixer_strip.cc @@ -152,7 +152,6 @@ MixerStrip::init () ignore_toggle = false; comment_area = 0; _width_owner = 0; - spacer = 0; /* the length of this string determines the width of the mixer strip when it is set to `wide' */ longest_label = "longest label"; @@ -322,6 +321,15 @@ MixerStrip::init () global_vpacker.pack_start (name_button, Gtk::PACK_SHRINK); } + //add a spacer underneath the master bus; + //this fills the area that is taken up by the scrollbar on the tracks; + //and therefore keeps the faders "even" across the bottom + HScrollbar scrollbar; + Gtk::Requisition requisition(scrollbar.size_request ()); + int scrollbar_height = requisition.height; + spacer.set_size_request (-1, scrollbar_height+2); //+2 is a fudge factor to accomodate extra padding in mixer strip + global_vpacker.pack_end (spacer, false, false); + global_frame.add (global_vpacker); global_frame.set_shadow_type (Gtk::SHADOW_IN); global_frame.set_name ("BaseFrame"); @@ -557,15 +565,9 @@ MixerStrip::set_route (boost::shared_ptr<Route> rt) } if (_mixer_owned && route()->is_master() ) { - - HScrollbar scrollbar; - Gtk::Requisition requisition(scrollbar.size_request ()); - int scrollbar_height = requisition.height; - - spacer = manage (new EventBox); - spacer->set_size_request (-1, scrollbar_height+2); - global_vpacker.pack_start (*spacer, false, false); - spacer->show(); + spacer.show(); + } else { + spacer.hide(); } if (is_track()) { |