mirror of
https://github.com/iNavFlight/inav-configurator.git
synced 2025-07-16 04:45:18 +03:00
Universal Sliders for Settings framework
This commit is contained in:
parent
611b5895ec
commit
1d3ceacb14
3 changed files with 135 additions and 21 deletions
|
@ -57,4 +57,10 @@ function generateFilename(prefix, suffix) {
|
|||
+ zeroPad(date.getSeconds(), 2);
|
||||
|
||||
return filename + '.' + suffix;
|
||||
}
|
||||
}
|
||||
|
||||
function scaleRangeInt(x, srcMin, srcMax, destMin, destMax) {
|
||||
let a = (destMax - destMin) * (x - srcMin);
|
||||
let b = srcMax - srcMin;
|
||||
return Math.round((a / b) + destMin);
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue