diff options
Diffstat (limited to 'qt-ui/modeldelegates.h')
-rw-r--r-- | qt-ui/modeldelegates.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/qt-ui/modeldelegates.h b/qt-ui/modeldelegates.h index 94ffe0868..173151a4a 100644 --- a/qt-ui/modeldelegates.h +++ b/qt-ui/modeldelegates.h @@ -2,7 +2,7 @@ #define MODELDELEGATES_H #include <QStyledItemDelegate> -class QComboBox; +#include <QComboBox> class QPainter; class DiveListDelegate : public QStyledItemDelegate { @@ -59,6 +59,15 @@ slots: void revertModelData(QWidget *widget, QAbstractItemDelegate::EndEditHint hint); }; +class TankUseDelegate : public QStyledItemDelegate { + Q_OBJECT +public: + explicit TankUseDelegate(QObject *parent = 0); + virtual void setModelData(QWidget *editor, QAbstractItemModel *model, const QModelIndex &index) const; + virtual QWidget *createEditor(QWidget *parent, const QStyleOptionViewItem &option, const QModelIndex &index) const; + virtual void setEditorData(QWidget * editor, const QModelIndex & index) const; +}; + class WSInfoDelegate : public ComboBoxDelegate { Q_OBJECT public: |