Skip to content

Commit 01d0f87

Browse files
committed
Improved computing of top margin value at vs RPM charts
1 parent 27d8c15 commit 01d0f87

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/graph_spectrum_calc.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -480,7 +480,7 @@ GraphSpectrumCalc._getFlightSamplesFreqVsX = function(vsFieldNames, minValue = I
480480

481481
// Use small top margin for RPM axis only. Because it has bad axis view for throttle
482482
if (vsFieldNames == FIELD_RPM_NAMES) {
483-
maxValue *= 1 + RPM_AXIS_TOP_MARGIN_PERCENT / 100;
483+
maxValue += (maxValue - minValue) * RPM_AXIS_TOP_MARGIN_PERCENT / 100;
484484
}
485485

486486
if (minValue > maxValue) {

0 commit comments

Comments
 (0)