diff --git a/src/UI/xcvr_setup.cxx b/src/UI/xcvr_setup.cxx index 5f0976f9..8d45968a 100644 --- a/src/UI/xcvr_setup.cxx +++ b/src/UI/xcvr_setup.cxx @@ -91,6 +91,7 @@ Fl_Value_Input *poll_split = (Fl_Value_Input *)0; Fl_Value_Input *poll_noise = (Fl_Value_Input *)0; Fl_Value_Input *poll_nr = (Fl_Value_Input *)0; Fl_Value_Input *poll_compression = (Fl_Value_Input *)0; +Fl_Value_Input *poll_tuner = (Fl_Value_Input *)0; Fl_Button *btnClearAddControls = (Fl_Button *)0; Fl_Value_Input *poll_meters = (Fl_Value_Input *)0; @@ -522,6 +523,10 @@ static void cb_poll_compression(Fl_Value_Input* o, void *) { progStatus.poll_compression = o->value(); } +static void cb_poll_tuner(Fl_Value_Input* o, void *) { + progStatus.poll_tuner = o->value(); +} + static void cb_poll_meters(Fl_Value_Input* o, void*) { progStatus.poll_meters = o->value(); } @@ -570,6 +575,7 @@ static void cb_btnSetAdd(Fl_Button*, void*) { poll_noise->value(progStatus.poll_all); poll_nr->value(progStatus.poll_all); poll_compression->value(progStatus.poll_all); + poll_tuner->value(progStatus.poll_all); progStatus.poll_volume = progStatus.poll_all; progStatus.poll_micgain = progStatus.poll_all; @@ -584,6 +590,7 @@ static void cb_btnSetAdd(Fl_Button*, void*) { progStatus.poll_noise = progStatus.poll_all; progStatus.poll_nr = progStatus.poll_all; progStatus.poll_compression = progStatus.poll_all; + progStatus.poll_tuner = progStatus.poll_all; } static void cb_btn_send_command(Fl_Button *o, void*) { @@ -1429,6 +1436,14 @@ Fl_Group *createPOLLING(int X, int Y, int W, int H, const char *label) poll_auto_notch->align(Fl_Align(FL_ALIGN_RIGHT)); poll_auto_notch->value(progStatus.poll_auto_notch); + poll_tuner = new Fl_Value_Input(X + 280, Y + 140, 30, 20, _("Tuner")); + poll_tuner->tooltip(_("Auto Tuner")); + poll_tuner->maximum(10); + poll_tuner->step(1); + poll_tuner->callback((Fl_Callback*)cb_poll_tuner); + poll_tuner->align(Fl_Align(FL_ALIGN_RIGHT)); + poll_tuner->value(progStatus.poll_tuner); + poll_pre_att = new Fl_Value_Input(X + 10, Y + 165, 30, 20, _("Pre/Att")); poll_pre_att->tooltip(_("Preamp / Attenuator")); poll_pre_att->maximum(10); diff --git a/src/include/status.h b/src/include/status.h index b0b8e98b..4138fbce 100644 --- a/src/include/status.h +++ b/src/include/status.h @@ -91,6 +91,7 @@ struct status { int poll_meters; int poll_ops; int poll_compression; + int poll_tuner; int poll_all; int iBW_A; diff --git a/src/support/status.cxx b/src/support/status.cxx index 40851962..a905b7fb 100644 --- a/src/support/status.cxx +++ b/src/support/status.cxx @@ -102,6 +102,7 @@ status progStatus = { 1, // poll_meters; 1, // poll_ops; 1, // poll_compression; + 1, // poll_tuner; 4, // int poll_all; -1, // int iBW_A; @@ -490,6 +491,7 @@ void status::saveLastState() spref.set("poll_noise", poll_noise); spref.set("poll_nr", poll_nr); spref.set("poll_compression", poll_compression); + spref.set("poll_tuner", poll_tuner); spref.set("poll_all", poll_all); spref.set("bw_A", iBW_A); @@ -930,6 +932,7 @@ bool status::loadXcvrState(string xcvr) spref.get("poll_noise", poll_noise, poll_noise); spref.get("poll_nr", poll_nr, poll_nr); spref.get("poll_compression", poll_compression, poll_compression); + spref.get("poll_tuner", poll_tuner, poll_tuner); spref.get("poll_all", poll_all, poll_all); spref.get("bw_A", iBW_A, iBW_A); diff --git a/src/support/support.cxx b/src/support/support.cxx index 2eccc767..305d7d57 100644 --- a/src/support/support.cxx +++ b/src/support/support.cxx @@ -1061,7 +1061,7 @@ POLL_PAIR RX_poll_pairs[] = { {&progStatus.poll_mode, read_mode}, {&progStatus.poll_bandwidth, read_bandwidth}, {&progStatus.poll_smeter, read_smeter}, - {&progStatus.poll_smeter, read_tuner}, + {&progStatus.poll_tuner, read_tuner}, {&progStatus.poll_volume, read_volume}, {&progStatus.poll_auto_notch, read_auto_notch}, {&progStatus.poll_notch, read_notch},