diff --git a/src/opengl/qopenglcompositorbackingstore.cpp b/src/opengl/qopenglcompositorbackingstore.cpp index 052f29d41e6..20c86fb8adc 100644 --- a/src/opengl/qopenglcompositorbackingstore.cpp +++ b/src/opengl/qopenglcompositorbackingstore.cpp @@ -141,6 +141,10 @@ void QOpenGLCompositorBackingStore::flush(QWindow *flushedWindow, const QRegion Q_UNUSED(region); Q_UNUSED(offset); + QOpenGLCompositorWindow *handle = dynamic_cast(flushedWindow->handle()); + if (handle && !handle->backingStore()) + handle->setBackingStore(this); + if (!rhi(flushedWindow)) { QPlatformBackingStoreRhiConfig rhiConfig; rhiConfig.setApi(QPlatformBackingStoreRhiConfig::OpenGL);