mirror of
https://github.com/jketterl/openwebrx.git
synced 2026-04-05 06:26:50 +00:00
allow negative frequencies in exponential display, closes #247
This commit is contained in:
parent
0258a75650
commit
c46b3275a9
1 changed files with 1 additions and 1 deletions
|
|
@ -38,7 +38,7 @@ $.fn.exponentialInput = function() {
|
|||
// calculate initial exponent
|
||||
var value = parseFloat($input.val());
|
||||
if (!Number.isNaN(value)) {
|
||||
$exponent.val(Math.floor(Math.log10(value) / 3) * 3);
|
||||
$exponent.val(Math.floor(Math.log10(Math.abs(value)) / 3) * 3);
|
||||
setExponent();
|
||||
}
|
||||
})
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue