summaryrefslogtreecommitdiffstats
path: root/examples/widgets/itemviews/spinboxdelegate/delegate.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'examples/widgets/itemviews/spinboxdelegate/delegate.cpp')
-rw-r--r--examples/widgets/itemviews/spinboxdelegate/delegate.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/examples/widgets/itemviews/spinboxdelegate/delegate.cpp b/examples/widgets/itemviews/spinboxdelegate/delegate.cpp
index 2967b6ae38..974ec265fb 100644
--- a/examples/widgets/itemviews/spinboxdelegate/delegate.cpp
+++ b/examples/widgets/itemviews/spinboxdelegate/delegate.cpp
@@ -52,7 +52,7 @@
//! [0]
SpinBoxDelegate::SpinBoxDelegate(QObject *parent)
- : QItemDelegate(parent)
+ : QStyledItemDelegate(parent)
{
}
//! [0]
@@ -63,6 +63,7 @@ QWidget *SpinBoxDelegate::createEditor(QWidget *parent,
const QModelIndex &/* index */) const
{
QSpinBox *editor = new QSpinBox(parent);
+ editor->setFrame(false);
editor->setMinimum(0);
editor->setMaximum(100);