summaryrefslogtreecommitdiffstats
path: root/src/gui/widgets/qabstractspinbox.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/gui/widgets/qabstractspinbox.cpp')
-rw-r--r--src/gui/widgets/qabstractspinbox.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/gui/widgets/qabstractspinbox.cpp b/src/gui/widgets/qabstractspinbox.cpp
index 4372ae3..7a985a1 100644
--- a/src/gui/widgets/qabstractspinbox.cpp
+++ b/src/gui/widgets/qabstractspinbox.cpp
@@ -1655,6 +1655,8 @@ void QAbstractSpinBox::initStyleOption(QStyleOptionSpinBox *option) const
: (QAbstractSpinBox::StepDownEnabled|QAbstractSpinBox::StepUpEnabled);
option->frame = d->frame;
+ if (d->readOnly)
+ option->state |= QStyle::State_ReadOnly;
}
/*!