summaryrefslogtreecommitdiffstats
path: root/qt-ui/diveplanner.cpp
diff options
context:
space:
mode:
authorGravatar Robert C. Helling <helling@atdotde.de>2014-05-18 22:18:46 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2014-05-26 09:58:23 -0700
commit1093d6235b5657746f2cb4524ed08cf13c80c3bb (patch)
tree76e9a3ca520fd538ad69529d469c8ab5aab4788c /qt-ui/diveplanner.cpp
parent04b6b6aaf9cc194a698c2302abc2032f730aecb4 (diff)
downloadsubsurface-1093d6235b5657746f2cb4524ed08cf13c80c3bb.tar.gz
Reenabled copying the diveplan to dive notes.
Gas consumption calculation fixed. Pressure difference still needs cylinder size to be set. Signed-off-by: Robert C. Helling <helling@atdotde.de> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/diveplanner.cpp')
-rw-r--r--qt-ui/diveplanner.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/qt-ui/diveplanner.cpp b/qt-ui/diveplanner.cpp
index 24aa7f697..6d2ec195c 100644
--- a/qt-ui/diveplanner.cpp
+++ b/qt-ui/diveplanner.cpp
@@ -1069,7 +1069,8 @@ bool DivePlannerPointsModel::recalcQ()
void DivePlannerPointsModel::emitCylinderModelEdited()
{
- cylinderModelEdited();
+ if (isPlanner())
+ cylinderModelEdited();
}
int DivePlannerPointsModel::columnCount(const QModelIndex &parent) const
@@ -1199,13 +1200,13 @@ DivePlannerPointsModel *DivePlannerPointsModel::instance()
void DivePlannerPointsModel::setBottomSac(int sac)
{
- diveplan.bottomsac = sac;
+ diveplan.bottomsac = sac * 1000;
emit dataChanged(createIndex(0, 0), createIndex(rowCount() - 1, COLUMNS - 1));
}
void DivePlannerPointsModel::setDecoSac(int sac)
{
- diveplan.decosac = sac;
+ diveplan.decosac = sac * 1000;
emit dataChanged(createIndex(0, 0), createIndex(rowCount() - 1, COLUMNS - 1));
}