mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
Calculate approx gas bill on dives
This uses a bit of naive gas computations to figure out how much of different base gases you used up on the dives the statistics is done for. It's quite useful to get a minimum line about how big your gas bill is going to be after a dive trip. Signed-off-by: Anton Lundin <glance@acc.umu.se> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
parent
c020cda41b
commit
b2288e1e3d
3 changed files with 40 additions and 0 deletions
|
@ -552,6 +552,9 @@ void MainTab::updateDiveInfo(int dive)
|
|||
}
|
||||
if (!gasUsed.isEmpty())
|
||||
gasUsedString.append("...");
|
||||
volume_t o2_tot = {}, he_tot = {};
|
||||
selected_dives_gas_parts(&o2_tot, &he_tot);
|
||||
gasUsedString.append(QString("These gases could be\nmixed from Air and using:\nHe: %1 and O2: %2\n").arg(get_volume_string(he_tot, true)).arg(get_volume_string(o2_tot, true)));
|
||||
ui.gasConsumption->setText(gasUsedString);
|
||||
} else {
|
||||
/* clear the fields */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue