diff options
Diffstat (limited to 'qt-models/diveplannermodel.cpp')
| -rw-r--r-- | qt-models/diveplannermodel.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/qt-models/diveplannermodel.cpp b/qt-models/diveplannermodel.cpp index bb52a1061..e0c0e2d69 100644 --- a/qt-models/diveplannermodel.cpp +++ b/qt-models/diveplannermodel.cpp @@ -106,9 +106,10 @@ void DivePlannerPointsModel::loadFromDive(dive *d) duration_t lasttime = { 0 }; duration_t lastrecordedtime = {}; duration_t newtime = {}; + + clear(); free_dps(&diveplan); - if (mode != PLAN) - clear(); + diveplan.when = d->when; // is this a "new" dive where we marked manually entered samples? // if yes then the first sample should be marked |