summaryrefslogtreecommitdiffstats
path: root/qt-ui/models.h
diff options
context:
space:
mode:
Diffstat (limited to 'qt-ui/models.h')
-rw-r--r--qt-ui/models.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/qt-ui/models.h b/qt-ui/models.h
index ec15174f6..439ff05df 100644
--- a/qt-ui/models.h
+++ b/qt-ui/models.h
@@ -135,6 +135,21 @@ public:
TreeItem *parent;
};
+struct DiveItem : public TreeItem {
+ enum Column {NR, DATE, RATING, DEPTH, DURATION, TEMPERATURE, TOTALWEIGHT,
+ SUIT, CYLINDER, NITROX, SAC, OTU, MAXCNS, LOCATION, COLUMNS };
+
+ virtual QVariant data(int column, int role) const;
+ struct dive* dive;
+
+ QString displayDuration() const;
+ QString displayDepth() const;
+ QString displayTemperature() const;
+ QString displayWeight() const;
+ QString displaySac() const;
+ int weight() const;
+};
+
struct TripItem;
class TreeModel : public QAbstractItemModel