Revert "change the peak display widget from Gtkmm2ext::FocusEntry to ArdourButton, since it is absolutely not editable."

This reverts commit 58f7d02bf2.

Conflicts:
	gtk2_ardour/default_ui_config.in
	gtk2_ardour/gain_meter.cc
This commit is contained in:
Paul Davis 2014-10-28 10:12:01 -04:00
parent 4ed910748c
commit 0abcce0735
4 changed files with 8 additions and 14 deletions

View File

@ -235,7 +235,6 @@ BUTTON_VARS(MixerStripNameButton, "mixer strip name button")
BUTTON_VARS(MidiInputButton, "midi input button")
BUTTON_VARS(LockButton, "lock button")
BUTTON_VARS(GenericButton, "generic button")
BUTTON_VARS(PeakDisplayButton, "peak display")
#define CLOCK_VARS(root,name) \
CANVAS_VARIABLE(root ## Background, name ": background") \

View File

@ -285,12 +285,6 @@
<Option name="monitor solo exclusive: led active" value="ffa500ff"/>
<Option name="monitor solo exclusive: text" value="c7c7d8ff"/>
<Option name="monitor solo exclusive: text active" value="c8c8d9ff"/>
<Option name="peak display: fill" value="171717ff"/>
<Option name="peak display: fill active" value="e21b1bff"/>
<Option name="peak display: led" value="00000000"/>
<Option name="peak display: led active" value="00000000"/>
<Option name="peak display: text" value="ffffffff"/>
<Option name="peak display: text active" value="000000ff"/>
<Option name="rude solo: fill" value="684d4dff"/>
<Option name="rude solo: fill active" value="e21b1bff"/>
<Option name="rude solo: led" value="00000000"/>

View File

@ -101,11 +101,12 @@ GainMeterBase::GainMeterBase (Session* s, bool horizontal, int fader_length, int
gain_display.signal_focus_out_event().connect (sigc::mem_fun (*this, &GainMeter::gain_focused), false);
gain_display.set_alignment(0.5);
peak_display.set_name ("peak display");
peak_display.set_layout_font (ARDOUR_UI::config()->get_SmallFont());
peak_display.set_name ("MixerStripPeakDisplay");
set_size_request_to_display_given_text (peak_display, "-80.g", 2, 6); /* note the descender */
max_peak = minus_infinity();
peak_display.set_text (_("-inf"));
peak_display.set_alignment (0.5, 0.5);
peak_display.unset_flags (Gtk::CAN_FOCUS);
peak_display.set_alignment(0.5);
gain_automation_style_button.set_name ("mixer strip button");
gain_automation_state_button.set_name ("mixer strip button");
@ -364,7 +365,7 @@ GainMeterBase::reset_peak_display ()
level_meter->clear_meters();
max_peak = -INFINITY;
peak_display.set_text (_("-inf"));
peak_display.set_active (false);
peak_display.set_name ("MixerStripPeakDisplay");
}
void
@ -865,9 +866,8 @@ GainMeterBase::update_meters()
peak_display.set_text (buf);
}
}
if (mpeak >= Config->get_meter_peak()) {
peak_display.set_active (true);
peak_display.set_name ("MixerStripPeakDisplayPeak");
}
}

View File

@ -113,7 +113,8 @@ class GainMeterBase : virtual public sigc::trackable, ARDOUR::SessionHandlePtr
Gtkmm2ext::SliderController *gain_slider;
Gtk::Adjustment gain_adjustment;
Gtkmm2ext::FocusEntry gain_display;
ArdourButton peak_display;
Gtkmm2ext::FocusEntry peak_display;
// Gtk::Button peak_display;
Gtk::DrawingArea meter_metric_area;
Gtk::DrawingArea meter_ticks1_area;
Gtk::DrawingArea meter_ticks2_area;