summaryrefslogtreecommitdiffstats
path: root/qt-ui/diveplanner.cpp
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2014-07-29 12:50:50 -0700
committerGravatar Dirk Hohndel <dirk@hohndel.org>2014-07-29 13:02:01 -0700
commit936f057ddc963d9ea0e60c94c261275deca85458 (patch)
treeb70369e55588dddd337df16f9aa7f33f43e576de /qt-ui/diveplanner.cpp
parentd262886a2dccccbc01413c05a302be9044433a76 (diff)
downloadsubsurface-936f057ddc963d9ea0e60c94c261275deca85458.tar.gz
Retain the start time when creating plan from dive
We need to make sure that the start time is set before we start adding points. Fixes #661 Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/diveplanner.cpp')
-rw-r--r--qt-ui/diveplanner.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/qt-ui/diveplanner.cpp b/qt-ui/diveplanner.cpp
index 62c4e56a4..1841f8529 100644
--- a/qt-ui/diveplanner.cpp
+++ b/qt-ui/diveplanner.cpp
@@ -109,6 +109,7 @@ void DivePlannerPointsModel::loadFromDive(dive *d)
CylindersModel::instance()->updateDive();
duration_t lasttime = {};
struct gasmix gas;
+ diveplan.when = d->when;
for (int i = 0; i < d->dc.samples - 1; i++) {
const sample &s = d->dc.sample[i];
if (s.time.seconds == 0)