aboutsummaryrefslogtreecommitdiffstats
path: root/qt-ui
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2014-08-19 15:49:18 -0500
committerGravatar Dirk Hohndel <dirk@hohndel.org>2014-08-19 21:18:26 -0500
commitd7630032e29947d4212ac21418040dd724692cba (patch)
tree766869e878472a7624ab23467777382a0b30675e /qt-ui
parenta85a219df3250e9a4c4336ea4b6f4a59f4ee9963 (diff)
downloadsubsurface-d7630032e29947d4212ac21418040dd724692cba.tar.gz
Planner: clear out model before re-planning a dive
Otherwise points from a previous run might be around. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui')
-rw-r--r--qt-ui/mainwindow.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/qt-ui/mainwindow.cpp b/qt-ui/mainwindow.cpp
index 92cc67f8f..b74c34723 100644
--- a/qt-ui/mainwindow.cpp
+++ b/qt-ui/mainwindow.cpp
@@ -460,6 +460,7 @@ void MainWindow::on_actionReplanDive_triggered()
}
ui.ListWidget->endSearch();
// put us in PLAN mode
+ DivePlannerPointsModel::instance()->clear();
DivePlannerPointsModel::instance()->setPlanMode(DivePlannerPointsModel::PLAN);
ui.newProfile->setPlanState();