Windows: Fix a crash in Vista style.
Do not query the paintDevice of a backing store that has not received a resize yet. Change-Id: I49bf8f7e85c092c5664e5bc507802bd2cd8b62ea Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>bb10
parent
af0df2d047
commit
77a8bd1e01
|
|
@ -731,8 +731,9 @@ void QWindowsXPStylePrivate::drawBackground(XPThemeData &themeData)
|
|||
canDrawDirectly = true;
|
||||
break;
|
||||
case QInternal::Image:
|
||||
// Ensure the backing store has received as resize and is initialized.
|
||||
if (QBackingStore *bs = backingStoreForWidget(themeData.widget))
|
||||
if (bs->paintDevice() == enginePaintDevice)
|
||||
if (bs->size().isValid() && bs->paintDevice() == enginePaintDevice)
|
||||
canDrawDirectly = true;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue