diff options
author | Markus Goetz <Markus.Goetz@nokia.com> | 2009-05-04 14:29:39 +0200 |
---|---|---|
committer | Markus Goetz <Markus.Goetz@nokia.com> | 2009-05-06 17:40:25 +0200 |
commit | 9f7e8dcd408f8a082d6b8355c78c692d71becbb8 (patch) | |
tree | 9a81c66258b758f08dc254579dec3ef0246b4c0f /src/gui | |
parent | 67c2b69d45eb43078b7e4193ced6cd513602483c (diff) | |
download | qt4-tools-9f7e8dcd408f8a082d6b8355c78c692d71becbb8.tar.gz |
Fix crash in QWebView when application has a style sheet
Task: 252796
Rev-By: Tor Arne
Diffstat (limited to 'src/gui')
-rw-r--r-- | src/gui/styles/qstylesheetstyle.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/styles/qstylesheetstyle.cpp b/src/gui/styles/qstylesheetstyle.cpp index 058660e105..714b8c50d9 100644 --- a/src/gui/styles/qstylesheetstyle.cpp +++ b/src/gui/styles/qstylesheetstyle.cpp @@ -4926,7 +4926,7 @@ QSize QStyleSheetStyle::sizeFromContents(ContentsType ct, const QStyleOption *op case CT_LineEdit: #ifndef QT_NO_SPINBOX // ### hopelessly broken QAbstractSpinBox (part 2) - if (QAbstractSpinBox *spinBox = qobject_cast<QAbstractSpinBox *>(w->parentWidget())) { + if (QAbstractSpinBox *spinBox = qobject_cast<QAbstractSpinBox *>(w ? w->parentWidget() : 0)) { QRenderRule rule = renderRule(spinBox, opt); if (rule.hasBox() || !rule.hasNativeBorder()) return csz; |