add 4 harrison-style vca assign buttons to the mixer strip

This commit is contained in:
Paul Davis 2016-02-29 09:10:13 -05:00
parent 8eafe8b804
commit 089549acb6
4 changed files with 34 additions and 14 deletions

View File

@ -79,9 +79,10 @@ using namespace std;
using namespace ArdourMeter;
MixerStrip* MixerStrip::_entered_mixer_strip;
PBD::Signal1<void,MixerStrip*> MixerStrip::CatchDeletion;
static const uint32_t n_vca_buttons = 4;
MixerStrip::MixerStrip (Mixer_UI& mx, Session* sess, bool in_mixer)
: AxisView(sess)
, RouteUI (sess)
@ -95,6 +96,7 @@ MixerStrip::MixerStrip (Mixer_UI& mx, Session* sess, bool in_mixer)
, solo_iso_table (1, 2)
, mute_solo_table (1, 2)
, bottom_button_table (1, 3)
, vca_table (1, 4)
, meter_point_button (_("pre"))
, monitor_section_button (0)
, midi_input_enable_button (0)
@ -126,6 +128,7 @@ MixerStrip::MixerStrip (Mixer_UI& mx, Session* sess, boost::shared_ptr<Route> rt
, solo_iso_table (1, 2)
, mute_solo_table (1, 2)
, bottom_button_table (1, 3)
, vca_table (1, 4)
, meter_point_button (_("pre"))
, monitor_section_button (0)
, midi_input_enable_button (0)
@ -209,6 +212,17 @@ MixerStrip::init ()
}
solo_iso_table.show ();
vca_table.set_homogeneous (true);
vca_table.set_spacings (1);
for (uint32_t n = 0; n < n_vca_buttons; ++n) {
ArdourButton* v = manage (new ArdourButton (ArdourButton::default_elements));
vca_buttons.push_back (v); /* no ownership transfer, button is managed by its container */
vca_table.attach (*v, n, n+1, 0, 1);
v->show ();
v->set_text ("a");
}
vca_table.show ();
rec_mon_table.set_homogeneous (true);
rec_mon_table.set_row_spacings (2);
rec_mon_table.set_col_spacings (2);
@ -304,6 +318,7 @@ MixerStrip::init ()
global_vpacker.pack_start (solo_iso_table, Gtk::PACK_SHRINK);
global_vpacker.pack_start (mute_solo_table, Gtk::PACK_SHRINK);
global_vpacker.pack_start (gpm, Gtk::PACK_SHRINK);
global_vpacker.pack_start (vca_table, Gtk::PACK_SHRINK);
global_vpacker.pack_start (bottom_button_table, Gtk::PACK_SHRINK);
if (!ARDOUR::Profile->get_trx()) {
global_vpacker.pack_start (output_button, Gtk::PACK_SHRINK);
@ -385,6 +400,7 @@ MixerStrip::init ()
_visibility.add (&solo_iso_table, X_("SoloIsoLock"), _("Solo Iso / Lock"), false);
_visibility.add (&output_button, X_("Output"), _("Output"), false);
_visibility.add (&_comment_button, X_("Comments"), _("Comments"), false);
_visibility.add (&vca_table, X_("VCA"), _("VCA Assigns"), false);
parameter_changed (X_("mixer-element-visibility"));
UIConfiguration::instance().ParameterChanged.connect (sigc::mem_fun (*this, &MixerStrip::parameter_changed));

View File

@ -176,6 +176,7 @@ class MixerStrip : public RouteUI, public Gtk::EventBox
Gtk::Table solo_iso_table;
Gtk::Table mute_solo_table;
Gtk::Table bottom_button_table;
Gtk::Table vca_table;
ArdourButton meter_point_button;

View File

@ -3130,6 +3130,7 @@ if (!ARDOUR::Profile->get_mixbus()) {
_mixer_strip_visibility.add (0, X_("SoloIsoLock"), _("Solo Iso / Lock"));
_mixer_strip_visibility.add (0, X_("Output"), _("Output"));
_mixer_strip_visibility.add (0, X_("Comments"), _("Comments"));
_mixer_strip_visibility.add (0, X_("VCA"), _("VCA Assigns"));
add_option (
S_("Preferences|GUI"),

View File

@ -126,6 +126,8 @@ class RouteUI : public virtual AxisView
ArdourButton* solo_safe_led;
ArdourButton* solo_isolated_led;
std::vector<ArdourButton*> vca_buttons;
Gtk::Label monitor_input_button_label;
Gtk::Label monitor_disk_button_label;