Guard against null-nativeParent in QWidgetBackingStore::markDirtyOnScreen
The back port in 1e310b5a4508f removed the check in two of the call sites for this function, that in 5.14 were handled elsewhere, but for 5.12 caused us to not guard against null-nativeParent windows anymore. Change-Id: I698c5a0b6a54bbee37b533fcafa75129768c5db1 Fixes: QTBUG-81315 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
This commit is contained in:
parent
bdccc51bc1
commit
07c33ab76f
@ -717,7 +717,11 @@ void QWidgetBackingStore::markDirtyOnScreen(const QRegion ®ion, QWidget *widg
|
||||
|
||||
// Alien widgets.
|
||||
if (!hasPlatformWindow(widget) && !widget->isWindow()) {
|
||||
QWidget *nativeParent = widget->nativeParentWidget(); // Alien widgets with the top-level as the native parent (common case).
|
||||
QWidget *nativeParent = widget->nativeParentWidget();
|
||||
if (!nativeParent)
|
||||
return;
|
||||
|
||||
// Alien widgets with the top-level as the native parent (common case).
|
||||
if (nativeParent == tlw) {
|
||||
dirtyOnScreen += region.translated(topLevelOffset);
|
||||
return;
|
||||
|
Loading…
x
Reference in New Issue
Block a user