aboutsummaryrefslogtreecommitdiffstats
path: root/qt-models
diff options
context:
space:
mode:
Diffstat (limited to 'qt-models')
-rw-r--r--qt-models/diveplannermodel.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/qt-models/diveplannermodel.cpp b/qt-models/diveplannermodel.cpp
index 4f4a86cdc..cdf340a3f 100644
--- a/qt-models/diveplannermodel.cpp
+++ b/qt-models/diveplannermodel.cpp
@@ -464,6 +464,7 @@ DivePlannerPointsModel *DivePlannerPointsModel::instance()
void DivePlannerPointsModel::emitDataChanged()
{
+ updateDiveProfile();
emit dataChanged(createIndex(0, 0), createIndex(rowCount() - 1, COLUMNS - 1));
}
@@ -1062,6 +1063,8 @@ static bool shouldComputeVariations()
void DivePlannerPointsModel::updateDiveProfile()
{
+ if (!d)
+ return;
createTemporaryPlan();
if (diveplan_empty(&diveplan))
return;