aboutsummaryrefslogtreecommitdiffstats
path: root/qt-models/divelistmodel.cpp
diff options
context:
space:
mode:
authorGravatar Berthold Stoeger <bstoeger@mail.tuwien.ac.at>2018-12-27 13:49:40 +0100
committerGravatar Dirk Hohndel <dirk@hohndel.org>2018-12-27 15:19:50 -0800
commit2dd0187fe827130dbe5a487cd08070fc7c3ae2a4 (patch)
treee157c3b150a49c65887ef5faf72871e1b356c5d2 /qt-models/divelistmodel.cpp
parent09a7736ae1e5a1569a3d9b9f6656baf72136c8e1 (diff)
downloadsubsurface-2dd0187fe827130dbe5a487cd08070fc7c3ae2a4.tar.gz
Cleanup: remove getDiveId() functions
These functions in DiveListSortModel and DiveListModel had no users. Remove them. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'qt-models/divelistmodel.cpp')
-rw-r--r--qt-models/divelistmodel.cpp13
1 files changed, 0 insertions, 13 deletions
diff --git a/qt-models/divelistmodel.cpp b/qt-models/divelistmodel.cpp
index 953229c45..e3934b604 100644
--- a/qt-models/divelistmodel.cpp
+++ b/qt-models/divelistmodel.cpp
@@ -61,12 +61,6 @@ int DiveListSortModel::shown()
return rowCount();
}
-int DiveListSortModel::getDiveId(int idx)
-{
- DiveListModel *mySourceModel = qobject_cast<DiveListModel *>(sourceModel());
- return mySourceModel->getDiveId(mapToSource(index(idx,0)).row());
-}
-
int DiveListSortModel::getIdxForId(int id)
{
for (int i = 0; i < rowCount(); i++) {
@@ -231,13 +225,6 @@ int DiveListModel::rowCount(const QModelIndex &) const
return m_dives.count();
}
-int DiveListModel::getDiveId(int idx) const
-{
- if (idx < 0 || idx >= m_dives.count())
- return -1;
- return m_dives[idx]->id();
-}
-
int DiveListModel::getDiveIdx(int id) const
{
int i;