summaryrefslogtreecommitdiffstats
path: root/qt-ui/modeldelegates.h
diff options
context:
space:
mode:
Diffstat (limited to 'qt-ui/modeldelegates.h')
-rw-r--r--qt-ui/modeldelegates.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/qt-ui/modeldelegates.h b/qt-ui/modeldelegates.h
index 7de676c6c..4ddf53df3 100644
--- a/qt-ui/modeldelegates.h
+++ b/qt-ui/modeldelegates.h
@@ -33,6 +33,9 @@ class TankInfoDelegate : public ComboBoxDelegate{
public:
explicit TankInfoDelegate(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;
+public slots:
+ void revertModelData(QWidget* widget, QAbstractItemDelegate::EndEditHint hint);
};
class WSInfoDelegate : public ComboBoxDelegate{
@@ -40,6 +43,7 @@ class WSInfoDelegate : public ComboBoxDelegate{
public:
explicit WSInfoDelegate(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;
};
#endif