Tuning step button restores default tuning step now.
This commit is contained in:
parent
a1bd9f4d9b
commit
dff515be46
@ -1354,4 +1354,4 @@ img.openwebrx-mirror-img
|
||||
|
||||
.openwebrx-waterfall-container > * {
|
||||
flex: 0 0 auto;
|
||||
}
|
||||
}
|
||||
|
@ -185,7 +185,7 @@
|
||||
<svg class="muted" viewBox="0 0 80 80"><use xlink:href="static/gfx/svg-defs.svg#speaker-muted"></use></svg>
|
||||
</div>
|
||||
<input title="Volume" id="openwebrx-panel-volume" class="openwebrx-panel-slider" type="range" min="0" max="150" value="50" step="1" onchange="updateVolume()" oninput="updateVolume()">
|
||||
<div title="Tuning step" class="openwebrx-button openwebrx-slider-button">
|
||||
<div title="Tuning step" class="openwebrx-button openwebrx-slider-button" onclick="tuning_step_reset();">
|
||||
<svg viewBox="0 0 80 80"><use xlink:href="static/gfx/svg-defs.svg#tuning-step"></use></svg>
|
||||
</div>
|
||||
<select id="openwebrx-tuning-step-listbox" class="openwebrx-panel-listbox" onchange="tuning_step_changed();">
|
||||
|
@ -31,6 +31,7 @@ var fft_compression = "none";
|
||||
var fft_codec;
|
||||
var waterfall_setup_done = 0;
|
||||
var secondary_fft_size;
|
||||
var tuning_step_default = 1;
|
||||
var tuning_step = 1;
|
||||
var nr_enabled = false;
|
||||
var nr_threshold = 0;
|
||||
@ -835,8 +836,8 @@ function on_ws_recv(evt) {
|
||||
$('#openwebrx-panel-receiver').demodulatorPanel().setTuningPrecision(config['tuning_precision']);
|
||||
|
||||
if ('tuning_step' in config) {
|
||||
tuning_step = config['tuning_step'];
|
||||
$('#openwebrx-tuning-step-listbox').val(tuning_step);
|
||||
tuning_step_default = config['tuning_step'];
|
||||
tuning_step_reset();
|
||||
}
|
||||
|
||||
break;
|
||||
@ -1630,6 +1631,11 @@ function tuning_step_changed() {
|
||||
tuning_step = parseInt($('#openwebrx-tuning-step-listbox').val());
|
||||
}
|
||||
|
||||
function tuning_step_reset() {
|
||||
$('#openwebrx-tuning-step-listbox').val(tuning_step_default);
|
||||
tuning_step = tuning_step_default;
|
||||
}
|
||||
|
||||
function nr_changed() {
|
||||
ws.send(JSON.stringify({
|
||||
"type": "connectionproperties",
|
||||
|
Loading…
Reference in New Issue
Block a user