dive planner: correct bottomsac/decosac calc.

Move conversion cuft <-> liter from desktop-widget/diveplanner.cpp
to plannerShared, to facilitate the same results in mobile
diveplanner

Use Backend for bottomsac/decosac and update to check
for switch LITER <-> CUFT

Add bottomsac/decosac to QMLinterface.

Signed-off-by: jan Iversen <jan@casacondor.com>
This commit is contained in:
jan Iversen 2020-01-08 12:06:23 +01:00 committed by Dirk Hohndel
parent 5548376776
commit cd3c2266f9
6 changed files with 49 additions and 18 deletions

View file

@ -554,8 +554,8 @@ void PlannerSettingsWidget::settingsChanged()
ui.bottomSAC->setSingleStep(0.1);
ui.decoStopSAC->setDecimals(2);
ui.decoStopSAC->setSingleStep(0.1);
ui.bottomSAC->setValue(ml_to_cuft(prefs.bottomsac));
ui.decoStopSAC->setValue(ml_to_cuft(prefs.decosac));
ui.bottomSAC->setValue(plannerShared::bottomsac());
ui.decoStopSAC->setValue(plannerShared::decosac());
} else {
ui.bottomSAC->setSuffix(tr("/min"));
ui.decoStopSAC->setSuffix(tr("/min"));