summaryrefslogtreecommitdiffstats
path: root/tests/manual/widgets/itemviews/delegate/example.cpp
diff options
context:
space:
mode:
authorChristian Ehrlicher <[email protected]>2023-10-04 16:34:16 +0200
committerChristian Ehrlicher <[email protected]>2023-10-05 21:08:45 +0200
commit4e8b54eb811f8c6064fd2e937711efe68543087c (patch)
tree28aca92c964de790d7953b22590cd3870d3d67b5 /tests/manual/widgets/itemviews/delegate/example.cpp
parent9ed25b413ff2e5055ec03fd6e1f8ba5dfcfc499a (diff)
Preparations to deprecate QItemDelegate
QItemDelegate was superseded since Qt4 by QStyledItemDelegate but it took until Qt6.7 to remove the last occurrences in qtbase. - remove unused includes / replace with qabstractitemdelegate.h - replace references in the documentation with QStyledItemDelegate - adjust the examples and tests to use QStyledItemDelegate Pick-to: 6.5 6.6 Change-Id: I246755004ce2d01192a726ca0972106c237df0cc Reviewed-by: Volker Hilsheimer <[email protected]> Reviewed-by: Paul Wicking <[email protected]>
Diffstat (limited to 'tests/manual/widgets/itemviews/delegate/example.cpp')
-rw-r--r--tests/manual/widgets/itemviews/delegate/example.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/manual/widgets/itemviews/delegate/example.cpp b/tests/manual/widgets/itemviews/delegate/example.cpp
index 3421b7790b1..9df2d87ee84 100644
--- a/tests/manual/widgets/itemviews/delegate/example.cpp
+++ b/tests/manual/widgets/itemviews/delegate/example.cpp
@@ -5,7 +5,7 @@
#include <QApplication>
#include <QTableView>
#include <QStandardItemModel>
-#include <QItemDelegate>
+#include <QStyledItemDelegate>
#include <QDebug>
#include <QComboBox>
@@ -16,10 +16,10 @@ public:
~ExampleEditor() { QApplication::instance()->quit(); }
};
-class ExampleDelegate : public QItemDelegate
+class ExampleDelegate : public QStyledItemDelegate
{
public:
- ExampleDelegate() : QItemDelegate()
+ ExampleDelegate() : QStyledItemDelegate()
{
m_editor = new ExampleEditor(0);
m_combobox = new QComboBox(0);