aboutsummaryrefslogtreecommitdiffstats
path: root/qt-ui/maintab.cpp
diff options
context:
space:
mode:
authorGravatar Gaetan Bisson <bisson@archlinux.org>2014-09-12 11:58:33 -1000
committerGravatar Dirk Hohndel <dirk@hohndel.org>2014-09-18 06:16:44 -0700
commitae6b0468b16200dcc01f8e1cfd43260b63e830dc (patch)
tree55fb299b1d63727c720506661482cd793864e718 /qt-ui/maintab.cpp
parent434e7a6a7173dcf6abe846e9972a01edce6a571b (diff)
downloadsubsurface-ae6b0468b16200dcc01f8e1cfd43260b63e830dc.tar.gz
Report CNS in dive info tab
This adds a maxcnsText widget under infoTab and populates it. Note that I manually edited maintab.ui to display CNS and OTU next to each other and right after gas data. Signed-off-by: Gaetan Bisson <bisson@archlinux.org> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/maintab.cpp')
-rw-r--r--qt-ui/maintab.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/qt-ui/maintab.cpp b/qt-ui/maintab.cpp
index 920aaeafc..95ac0563d 100644
--- a/qt-ui/maintab.cpp
+++ b/qt-ui/maintab.cpp
@@ -319,6 +319,7 @@ void MainTab::clearInfo()
{
ui.sacText->clear();
ui.otuText->clear();
+ ui.maxcnsText->clear();
ui.oxygenHeliumText->clear();
ui.gasUsedText->clear();
ui.dateText->clear();
@@ -475,6 +476,7 @@ void MainTab::updateDiveInfo(bool clear)
}
ui.maximumDepthText->setText(get_depth_string(displayed_dive.maxdepth, true));
ui.averageDepthText->setText(get_depth_string(displayed_dive.meandepth, true));
+ ui.maxcnsText->setText(QString("%1\%").arg(displayed_dive.maxcns));
ui.otuText->setText(QString("%1").arg(displayed_dive.otu));
ui.waterTemperatureText->setText(get_temperature_string(displayed_dive.watertemp, true));
ui.airTemperatureText->setText(get_temperature_string(displayed_dive.airtemp, true));