summaryrefslogtreecommitdiffstats
path: root/desktop-widgets/modeldelegates.h
diff options
context:
space:
mode:
authorGravatar Robert C. Helling <helling@atdotde.de>2018-05-08 17:26:48 +0200
committerGravatar Lubomir I. Ivanov <neolit123@gmail.com>2018-05-14 23:47:00 +0300
commitb8c94cad69e59e0b0584c23b39ca9a519c84db94 (patch)
treeff28a1a2dcbb845e24dd8ef6ca580c667c36aa62 /desktop-widgets/modeldelegates.h
parent969dfee9ec088acb942e211cb90329d2b8c0751f (diff)
downloadsubsurface-b8c94cad69e59e0b0584c23b39ca9a519c84db94.tar.gz
Planner: Add combo box for dive mode selection
I am not really sure what I am doing here but I copied code from the gas selection. Signed-off-by: Robert C. Helling <helling@atdotde.de>
Diffstat (limited to 'desktop-widgets/modeldelegates.h')
-rw-r--r--desktop-widgets/modeldelegates.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/desktop-widgets/modeldelegates.h b/desktop-widgets/modeldelegates.h
index 4c46d9b7c..a479b36f0 100644
--- a/desktop-widgets/modeldelegates.h
+++ b/desktop-widgets/modeldelegates.h
@@ -92,6 +92,16 @@ slots:
void revertModelData(QWidget *widget, QAbstractItemDelegate::EndEditHint hint);
};
+class DiveTypesDelegate : public ComboBoxDelegate {
+ Q_OBJECT
+public:
+ explicit DiveTypesDelegate(QObject *parent = 0);
+ virtual void setModelData(QWidget *editor, QAbstractItemModel *model, const QModelIndex &index) const;
+public
+slots:
+ void revertModelData(QWidget *widget, QAbstractItemDelegate::EndEditHint hint);
+};
+
class SpinBoxDelegate : public QStyledItemDelegate {
Q_OBJECT
public: