summaryrefslogtreecommitdiffstats
path: root/qt-ui
diff options
context:
space:
mode:
authorGravatar Lubomir I. Ivanov <neolit123@gmail.com>2015-03-13 02:32:48 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2015-03-14 18:17:22 -0700
commit3617928621e3e49699b495a12e7125cf909036df (patch)
tree9dc9c66c7f9afbf15d5663ba867d34abd5b6f6e0 /qt-ui
parentb47d8d5992da626f01620745d2a60d048734c4df (diff)
downloadsubsurface-3617928621e3e49699b495a12e7125cf909036df.tar.gz
Revert 4f9705f3f5
It solves #784, but introduces #846. Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui')
-rw-r--r--qt-ui/diveplanner.cpp9
1 files changed, 0 insertions, 9 deletions
diff --git a/qt-ui/diveplanner.cpp b/qt-ui/diveplanner.cpp
index 7a35daa59..db007218f 100644
--- a/qt-ui/diveplanner.cpp
+++ b/qt-ui/diveplanner.cpp
@@ -44,15 +44,6 @@ void DivePlannerPointsModel::removeSelectedPoints(const QVector<int> &rows)
QVector<int> v2 = rows;
std::sort(v2.begin(), v2.end(), intLessThan);
- /*
- * If we end up having divepoints that are not within the dive
- * profile, we need to just skip the removal to prevent
- * crashing due to index out of range.
- */
-
- if (rowCount() >= divepoints.count())
- return;
-
beginRemoveRows(QModelIndex(), firstRow, rowCount() - 1);
for (int i = v2.count() - 1; i >= 0; i--) {
divepoints.remove(v2[i]);