13
0

Amend df1e6fda2d, limit digits for numeric dB entry

This commit is contained in:
Robin Gareus 2020-07-22 22:20:48 +02:00
parent df1e6fda2d
commit 5a41ca8fdf
Signed by: rgareus
GPG Key ID: A090BCE02CF57F04

View File

@ -60,7 +60,11 @@ BarController::BarController (Gtk::Adjustment& adj,
Gtk::SpinButton& spinner = _slider.get_spin_button();
spinner.signal_activate().connect (mem_fun (*this, &BarController::entry_activated));
spinner.signal_focus_out_event().connect (mem_fun (*this, &BarController::entry_focus_out));
spinner.set_digits (4);
if (mc && mc->is_gain_like ()) {
spinner.set_digits (1); // 0.1 dB
} else {
spinner.set_digits (4);
}
spinner.set_numeric (true);
spinner.set_name ("BarControlSpinner");
add (_slider);