13
0

Disallow Selection, context-menu & drag-start on peak-display Button

This commit is contained in:
Robin Gareus 2017-03-23 01:53:31 +01:00
parent 4a180e68ba
commit 585fa4302f
2 changed files with 8 additions and 0 deletions

View File

@ -196,6 +196,7 @@ GainMeterBase::GainMeterBase (Session* s, bool horizontal, int fader_length, int
meter_point_button.signal_button_press_event().connect (sigc::mem_fun (*this, &GainMeter::meter_press), false); meter_point_button.signal_button_press_event().connect (sigc::mem_fun (*this, &GainMeter::meter_press), false);
gain_adjustment.signal_value_changed().connect (sigc::mem_fun(*this, &GainMeterBase::fader_moved)); gain_adjustment.signal_value_changed().connect (sigc::mem_fun(*this, &GainMeterBase::fader_moved));
peak_display.signal_button_press_event().connect (sigc::mem_fun(*this, &GainMeterBase::peak_button_press), false);
peak_display.signal_button_release_event().connect (sigc::mem_fun(*this, &GainMeterBase::peak_button_release), false); peak_display.signal_button_release_event().connect (sigc::mem_fun(*this, &GainMeterBase::peak_button_release), false);
gain_display.signal_key_press_event().connect (sigc::mem_fun(*this, &GainMeterBase::gain_key_press), false); gain_display.signal_key_press_event().connect (sigc::mem_fun(*this, &GainMeterBase::gain_key_press), false);
@ -426,6 +427,12 @@ GainMeterBase::gain_key_press (GdkEventKey* ev)
return true; return true;
} }
bool
GainMeterBase::peak_button_press (GdkEventButton* ev)
{
return true;
}
bool bool
GainMeterBase::peak_button_release (GdkEventButton* ev) GainMeterBase::peak_button_release (GdkEventButton* ev)
{ {

View File

@ -180,6 +180,7 @@ class GainMeterBase : virtual public sigc::trackable, ARDOUR::SessionHandlePtr
gint meter_button_press (GdkEventButton*, uint32_t); gint meter_button_press (GdkEventButton*, uint32_t);
bool peak_button_press (GdkEventButton*);
bool peak_button_release (GdkEventButton*); bool peak_button_release (GdkEventButton*);
bool gain_key_press (GdkEventKey*); bool gain_key_press (GdkEventKey*);