summaryrefslogtreecommitdiff
path: root/gtk2_ardour
diff options
context:
space:
mode:
authorPaul Davis <paul@linuxaudiosystems.com>2013-01-21 14:24:57 +0000
committerPaul Davis <paul@linuxaudiosystems.com>2013-01-21 14:24:57 +0000
commitdabd5bd174a6fc9cb529fe7c4fdffe726799f594 (patch)
treeab3342321cffb2e5e84474614dc19c460707edff /gtk2_ardour
parent7a2f3e63803802922ec4f3e565854177f1470bff (diff)
fix/revert/modify changes from 13617 that hide the gain + peak display from a generic GainMeter; name import dialog preview fader (fixes 5288)
git-svn-id: svn://localhost/ardour2/branches/3.0@13947 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'gtk2_ardour')
-rw-r--r--gtk2_ardour/gain_meter.cc13
-rw-r--r--gtk2_ardour/mixer_strip.cc37
-rw-r--r--gtk2_ardour/sfdb_ui.cc1
-rw-r--r--gtk2_ardour/startup.cc8
4 files changed, 25 insertions, 34 deletions
diff --git a/gtk2_ardour/gain_meter.cc b/gtk2_ardour/gain_meter.cc
index a405f074ae..23b62b4a41 100644
--- a/gtk2_ardour/gain_meter.cc
+++ b/gtk2_ardour/gain_meter.cc
@@ -854,7 +854,10 @@ GainMeter::GainMeter (Session* s, int fader_length)
, gain_display_box(true, 0)
, hbox(true, 2)
{
-// gain_display_box.pack_start (gain_display, true, true);
+ if (gain_display.get_parent()) {
+ gain_display.get_parent()->remove (gain_display);
+ }
+ gain_display_box.pack_start (gain_display, true, true);
meter_metric_area.set_name ("AudioTrackMetrics");
set_size_request_to_display_given_text (meter_metric_area, "-127", 0, 0);
@@ -901,9 +904,9 @@ GainMeter::set_controls (boost::shared_ptr<Route> r,
hbox.remove (meter_alignment);
}
-// if (peak_display.get_parent()) {
-// gain_display_box.remove (peak_display);
-// }
+ if (peak_display.get_parent()) {
+ peak_display.get_parent()->remove (peak_display);
+ }
// if (gain_automation_state_button.get_parent()) {
// fader_vbox->remove (gain_automation_state_button);
@@ -925,7 +928,7 @@ GainMeter::set_controls (boost::shared_ptr<Route> r,
pack some route-dependent stuff.
*/
-// gain_display_box.pack_end (peak_display, true, true);
+ gain_display_box.pack_end (peak_display, true, true);
hbox.pack_start (meter_alignment, true, true);
// if (r && !r->is_hidden()) {
diff --git a/gtk2_ardour/mixer_strip.cc b/gtk2_ardour/mixer_strip.cc
index 0f1d78d5bf..108d828a21 100644
--- a/gtk2_ardour/mixer_strip.cc
+++ b/gtk2_ardour/mixer_strip.cc
@@ -401,11 +401,11 @@ MixerStrip::set_route (boost::shared_ptr<Route> rt)
revert_to_default_display ();
if (gpm.gain_display.get_parent()) {
- middle_button_table.remove (gpm.gain_display);
+ gpm.gain_display.get_parent()->remove (gpm.gain_display);
}
if (gpm.peak_display.get_parent()) {
- middle_button_table.remove (gpm.peak_display);
+ gpm.peak_display.get_parent()->remove (gpm.peak_display);
}
if (solo_button->get_parent()) {
@@ -603,17 +603,22 @@ MixerStrip::set_width_enum (Width w, void* owner)
set_button_names ();
+ /* unpack these from the parent and stuff them into our own
+ table
+ */
+
+ if (gpm.peak_display.get_parent()) {
+ gpm.peak_display.get_parent()->remove (gpm.peak_display);
+ }
+ if (gpm.gain_display.get_parent()) {
+ gpm.gain_display.get_parent()->remove (gpm.gain_display);
+ }
+
+ middle_button_table.attach (gpm.gain_display,0,1,1,2);
+ middle_button_table.attach (gpm.peak_display,1,2,1,2);
+
switch (w) {
case Wide:
- if (!gpm.peak_display.get_parent()) {
- middle_button_table.attach (gpm.peak_display,1,2,1,2);
- }
- if (gpm.gain_display.get_parent()) {
- middle_button_table.remove (gpm.gain_display);
- }
- if (!gpm.gain_display.get_parent()) {
- middle_button_table.attach (gpm.gain_display,0,1,1,2);
- }
if (show_sends_button) {
show_sends_button->set_text (_("Aux\nSends"));
@@ -640,16 +645,6 @@ MixerStrip::set_width_enum (Width w, void* owner)
break;
case Narrow:
- if (gpm.peak_display.get_parent()) {
- middle_button_table.remove (gpm.peak_display);
- }
-
- if (gpm.gain_display.get_parent()) {
- middle_button_table.remove (gpm.gain_display);
- }
- if (!gpm.gain_display.get_parent()) {
- middle_button_table.attach (gpm.gain_display,0,2,1,2);
- }
if (show_sends_button) {
show_sends_button->set_text (_("Snd"));
diff --git a/gtk2_ardour/sfdb_ui.cc b/gtk2_ardour/sfdb_ui.cc
index 8dacd0dff1..f38b1b35ae 100644
--- a/gtk2_ardour/sfdb_ui.cc
+++ b/gtk2_ardour/sfdb_ui.cc
@@ -707,6 +707,7 @@ SoundFileBrowser::add_gain_meter ()
boost::shared_ptr<Route> r = _session->the_auditioner ();
gm->set_controls (r, r->shared_peak_meter(), r->amp());
+ gm->set_fader_name (X_("AudioTrackFader"));
meter_packer.set_border_width (12);
meter_packer.pack_start (*gm, false, true);
diff --git a/gtk2_ardour/startup.cc b/gtk2_ardour/startup.cc
index 91e48c15bc..213b912f03 100644
--- a/gtk2_ardour/startup.cc
+++ b/gtk2_ardour/startup.cc
@@ -63,12 +63,6 @@ static string poor_mans_glob (string path)
return copy;
}
-static void show_me (Gtk::FileChooserButton* fcb)
-{
- cerr << " Current folder of " << fcb << " changed to " << fcb->get_current_folder() << endl;
-}
-
-
ArdourStartup::ArdourStartup (bool require_new, const std::string& session_name, const std::string& session_path, const std::string& template_name)
: _response (RESPONSE_OK)
, config_modified (false)
@@ -99,8 +93,6 @@ Ardour will play NO role in monitoring"))
need_audio_setup = EngineControl::need_setup ();
need_session_info = (session_name.empty() || require_new);
- new_folder_chooser.signal_current_folder_changed().connect (sigc::bind (sigc::ptr_fun (show_me), &new_folder_chooser));
-
_provided_session_name = session_name;
_provided_session_path = session_path;