aboutsummaryrefslogtreecommitdiffstats
path: root/qt-models/divetripmodel.cpp
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2020-02-19 14:05:09 -0800
committerGravatar Dirk Hohndel <dirk@hohndel.org>2020-03-10 09:25:57 -0700
commit968278fe9125729b6dae163d1362d48adc53b554 (patch)
tree11ed9db5cea0842604933520186c286105f75b00 /qt-models/divetripmodel.cpp
parent56db02a6850baa8866edc8149fdad05f82d02df9 (diff)
downloadsubsurface-968278fe9125729b6dae163d1362d48adc53b554.tar.gz
core: add 'diveInTrip' role to underlying data model
This will allow us to offer differentiated options in the context menu. Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
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 a9fd3490b..7c6655ba8 100644
--- a/qt-models/divetripmodel.cpp
+++ b/qt-models/divetripmodel.cpp
@@ -229,6 +229,7 @@ QVariant DiveTripModelBase::diveData(const struct dive *d, int column, int role)
case MobileListModel::EndPressureRole: return getEndPressure(d);
case MobileListModel::FirstGasRole: return getFirstGas(d);
case MobileListModel::SelectedRole: return d->selected;
+ case MobileListModel::DiveInTripRole: return d->divetrip != NULL;
}
#endif
switch (role) {