summaryrefslogtreecommitdiffstats
path: root/qt-models
diff options
context:
space:
mode:
Diffstat (limited to 'qt-models')
-rw-r--r--qt-models/divetripmodel.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/qt-models/divetripmodel.cpp b/qt-models/divetripmodel.cpp
index 3b08e6838..fcba4a570 100644
--- a/qt-models/divetripmodel.cpp
+++ b/qt-models/divetripmodel.cpp
@@ -3,6 +3,7 @@
#include "metrics.h"
#include "divelist.h"
#include "helpers.h"
+#include <QIcon>
static int nitrox_sort_value(struct dive *dive)
{
@@ -178,6 +179,13 @@ QVariant DiveItem::data(int column, int role) const
break;
}
break;
+ case Qt::DecorationRole:
+ if (column == LOCATION)
+ if (dive_has_gps_location(dive)) {
+ IconMetrics im = defaultIconMetrics();
+ retVal = QIcon(":satellite").pixmap(im.sz_small, im.sz_small);
+ }
+ break;
case Qt::ToolTipRole:
switch (column) {
case NR: