summaryrefslogtreecommitdiffstats
path: root/qt-models/divetripmodel.cpp
diff options
context:
space:
mode:
authorGravatar Berthold Stoeger <bstoeger@mail.tuwien.ac.at>2020-04-13 23:04:30 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2020-04-13 16:55:15 -0700
commit0ccc0f04bb960ac00fa6175130125c8eed752072 (patch)
treec43303a2bf35f34ae8d17b099e10d8ec464ca5f8 /qt-models/divetripmodel.cpp
parentb4e0968ed5a8ff197272c58ed08c949d9c2c0813 (diff)
downloadsubsurface-0ccc0f04bb960ac00fa6175130125c8eed752072.tar.gz
dive sites: properly reload dive site model on desktop
In 9310d72943390f95d6742c2d5b40f025a40b4008, resetting of the dive sites was moved to DiveTripModelBase::reset(). This seemed like a good idea, because it means that the location list is reloaded every time the dive list is reset. Unfortunately that function is only used on mobile, thus on desktop the dive site model is not updated. Do that in MultiFilterSortModel::resetModel(), because this is always called when the dive list is reset. Desktop differs from mobile in that two different models are used depending on whether we are in list or in tree mode. Fixes #2749 Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
Diffstat (limited to 'qt-models/divetripmodel.cpp')
-rw-r--r--qt-models/divetripmodel.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/qt-models/divetripmodel.cpp b/qt-models/divetripmodel.cpp
index 174e5af54..784013bce 100644
--- a/qt-models/divetripmodel.cpp
+++ b/qt-models/divetripmodel.cpp
@@ -490,6 +490,7 @@ void DiveTripModelBase::clear()
emit diveListNotifier.numShownChanged();
}
+// Currently only used by the mobile models
void DiveTripModelBase::reset()
{
beginResetModel();