summaryrefslogtreecommitdiffstats
path: root/profile-widget
diff options
context:
space:
mode:
authorGravatar Berthold Stoeger <bstoeger@mail.tuwien.ac.at>2020-05-01 01:14:53 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2020-04-30 16:55:19 -0700
commit0c28821d2895e246295884891df02e924eb8e359 (patch)
treefe1f4c51071503b014e6feb2ca4fe764b898e95b /profile-widget
parent3ed36b2ab5344466eae5eba141b8b62ac4c966fc (diff)
downloadsubsurface-0c28821d2895e246295884891df02e924eb8e359.tar.gz
cleanup: replace Q_ASSERT by qWarning
These two Q_ASSERTs made no sense - their expression (a string literal) always evaluated to true. A qWarning() was intended here. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'profile-widget')
-rw-r--r--profile-widget/diveeventitem.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/profile-widget/diveeventitem.cpp b/profile-widget/diveeventitem.cpp
index 6001ef0ea..ecd64aba0 100644
--- a/profile-widget/diveeventitem.cpp
+++ b/profile-widget/diveeventitem.cpp
@@ -262,7 +262,7 @@ int DiveEventItem::depthAtTime(int time)
{
QModelIndexList result = dataModel->match(dataModel->index(0, DivePlotDataModel::TIME), Qt::DisplayRole, time);
if (result.isEmpty()) {
- Q_ASSERT("can't find a spot in the dataModel");
+ qWarning("can't find a spot in the dataModel");
hide();
return DEPTH_NOT_FOUND;
}
@@ -276,7 +276,7 @@ void DiveEventItem::recalculatePos(int speed)
QModelIndexList result = dataModel->match(dataModel->index(0, DivePlotDataModel::TIME), Qt::DisplayRole, internalEvent->time.seconds);
if (result.isEmpty()) {
- Q_ASSERT("can't find a spot in the dataModel");
+ qWarning("can't find a spot in the dataModel");
hide();
return;
}