Add a workaround for render-to-texture widgets in fullscreen windows
The performance optimization of falling back to flushing windows the normal (raster) way once no render-to-texture widgets are visible has issues with fullscreen windows, presumably due to the compositor's special handling of such windows. Disable our smartness and stick with composeAndFlush for ever in case the window is fullscreen. Change-Id: Ifb31e0d36bd0a3933fcfe55a9a7d502513d6e3cf Task-number: QTBUG-53515 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
This commit is contained in:
parent
bdb1c18e41
commit
1937a4e8b9
@ -1000,8 +1000,18 @@ static QPlatformTextureList *widgetTexturesFor(QWidget *tlw, QWidget *widget)
|
||||
static bool switchableWidgetComposition =
|
||||
QGuiApplicationPrivate::instance()->platformIntegration()
|
||||
->hasCapability(QPlatformIntegration::SwitchableWidgetComposition);
|
||||
if (!switchableWidgetComposition)
|
||||
if (!switchableWidgetComposition
|
||||
// The Windows compositor handles fullscreen OpenGL window specially. Besides
|
||||
// having trouble with popups, it also has issues with flip-flopping between
|
||||
// OpenGL-based and normal flushing. Therefore, stick with GL for fullscreen
|
||||
// windows. (QTBUG-53515)
|
||||
#if defined(Q_OS_WIN) && !defined(Q_OS_WINRT) && !defined(Q_OS_WINCE)
|
||||
|| tlw->windowState().testFlag(Qt::WindowFullScreen)
|
||||
#endif
|
||||
)
|
||||
{
|
||||
return qt_dummy_platformTextureList();
|
||||
}
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
Loading…
Reference in New Issue
Block a user