--- gigedit/trunk/src/gigedit/dimregionedit.cpp 2018/01/19 19:17:41 3408 +++ gigedit/trunk/src/gigedit/dimregionedit.cpp 2018/01/23 16:30:56 3409 @@ -28,6 +28,8 @@ # include #endif +#include "Settings.h" + VelocityCurve::VelocityCurve(double (gig::DimensionRegion::*getter)(uint8_t)) : getter(getter), dimreg(0) { set_size_request(80, 80); @@ -187,6 +189,16 @@ )); } +void EGStateOptions::on_show_tooltips_changed() { + const bool b = Settings::singleton()->showTooltips; + + checkBoxAttack.set_has_tooltip(b); + checkBoxAttackHold.set_has_tooltip(b); + checkBoxDecay1.set_has_tooltip(b); + checkBoxDecay2.set_has_tooltip(b); + checkBoxRelease.set_has_tooltip(b); +} + DimRegionEdit::DimRegionEdit() : velocity_curve(&gig::DimensionRegion::GetVelocityAttenuation), @@ -960,6 +972,12 @@ append_page(*table[4], _("Filter (2)")); append_page(*table[5], _("Pitch")); append_page(*table[6], _("Misc")); + + Settings::singleton()->showTooltips.get_proxy().signal_changed().connect( + sigc::mem_fun(*this, &DimRegionEdit::on_show_tooltips_changed) + ); + + on_show_tooltips_changed(); } DimRegionEdit::~DimRegionEdit() @@ -1067,6 +1085,19 @@ return label; } +void DimRegionEdit::on_show_tooltips_changed() { + const bool b = Settings::singleton()->showTooltips; + + buttonSelectSample.set_has_tooltip(b); + buttonNullSampleReference->set_has_tooltip(b); + wSample->set_has_tooltip(b); + + eEG1StateOptions.on_show_tooltips_changed(); + eEG2StateOptions.on_show_tooltips_changed(); + + set_has_tooltip(b); +} + void DimRegionEdit::nextPage() { if (firstRowInBlock < rowno - 1)