Changeset View
Changeset View
Standalone View
Standalone View
krusader/Panel/PanelView/krviewitemdelegate.h
Show All 24 Lines | |||||
25 | #include <QItemDelegate> | 25 | #include <QItemDelegate> | ||
26 | 26 | | |||
27 | class KrViewItemDelegate : public QItemDelegate | 27 | class KrViewItemDelegate : public QItemDelegate | ||
28 | { | 28 | { | ||
29 | public: | 29 | public: | ||
30 | explicit KrViewItemDelegate(QObject *parent = 0); | 30 | explicit KrViewItemDelegate(QObject *parent = 0); | ||
31 | 31 | | |||
32 | void paint(QPainter *painter, const QStyleOptionViewItem &option, | 32 | void paint(QPainter *painter, const QStyleOptionViewItem &option, | ||
33 | const QModelIndex &index) const Q_DECL_OVERRIDE; | 33 | const QModelIndex &index) const override; | ||
34 | void drawDisplay(QPainter *painter, const QStyleOptionViewItem &option, const QRect &rect, | 34 | void drawDisplay(QPainter *painter, const QStyleOptionViewItem &option, const QRect &rect, | ||
35 | const QString &text) const Q_DECL_OVERRIDE; | 35 | const QString &text) const override; | ||
36 | QWidget *createEditor(QWidget *parent, const QStyleOptionViewItem &sovi, | 36 | QWidget *createEditor(QWidget *parent, const QStyleOptionViewItem &sovi, | ||
37 | const QModelIndex &index) const Q_DECL_OVERRIDE; | 37 | const QModelIndex &index) const override; | ||
38 | void setEditorData(QWidget *editor, const QModelIndex &index) const Q_DECL_OVERRIDE; | 38 | void setEditorData(QWidget *editor, const QModelIndex &index) const override; | ||
39 | QSize sizeHint(const QStyleOptionViewItem &option, | 39 | QSize sizeHint(const QStyleOptionViewItem &option, | ||
40 | const QModelIndex &index) const Q_DECL_OVERRIDE; | 40 | const QModelIndex &index) const override; | ||
41 | bool eventFilter(QObject *object, QEvent *event) Q_DECL_OVERRIDE; | 41 | bool eventFilter(QObject *object, QEvent *event) override; | ||
42 | 42 | | |||
43 | private: | 43 | private: | ||
44 | mutable int _currentlyEdited; | 44 | mutable int _currentlyEdited; | ||
45 | mutable bool _dontDraw; | 45 | mutable bool _dontDraw; | ||
46 | }; | 46 | }; | ||
47 | 47 | | |||
48 | #endif | 48 | #endif |