summaryrefslogtreecommitdiffstats
path: root/qt-ui
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2015-01-29 14:00:19 -0800
committerGravatar Dirk Hohndel <dirk@hohndel.org>2015-01-29 14:00:19 -0800
commitcd992bd14a292ae7117b40e1c1d6d99660d2e2da (patch)
treef952529a8dbf021912ed33ddc4a1cb4ca163902e /qt-ui
parent4e40872fc0ec5df8fd24e71e142f79ce5333307e (diff)
downloadsubsurface-cd992bd14a292ae7117b40e1c1d6d99660d2e2da.tar.gz
Don't reimplement the clear() method
Much easier and clearer. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui')
-rw-r--r--qt-ui/mainwindow.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/qt-ui/mainwindow.cpp b/qt-ui/mainwindow.cpp
index d13585788..3b7333619 100644
--- a/qt-ui/mainwindow.cpp
+++ b/qt-ui/mainwindow.cpp
@@ -300,9 +300,7 @@ void MainWindow::closeCurrentFile()
clear_events();
- QList<DiveComputerNode> values = dcList.dcMap.values();
- for (int i = 0; i < values.size(); i++)
- dcList.rmDC(values.at(i).model, values.at(i).deviceId);
+ dcList.dcMap.clear();
}
void MainWindow::on_actionClose_triggered()