The DWM workaround is not needed when DWM composition is disabled
Signed-off-by: Yuhang Zhao <2546789017@qq.com>
This commit is contained in:
parent
9904a5077a
commit
c3c5ef0d5d
|
@ -376,7 +376,8 @@ bool FramelessHelperWin::nativeEventFilter(const QByteArray &eventType, void *me
|
|||
// is not correct. It confuses QPA's internal logic.
|
||||
clientRect->bottom += 1;
|
||||
#endif
|
||||
// Dirty hack to workaround the DWM flicker.
|
||||
if (Utilities::isDwmCompositionAvailable()) {
|
||||
// Dirty hack to workaround the resize flicker caused by DWM.
|
||||
LARGE_INTEGER freq = {};
|
||||
if (QueryPerformanceFrequency(&freq) == FALSE) {
|
||||
qWarning() << Utilities::getSystemErrorMessage(QStringLiteral("QueryPerformanceFrequency"));
|
||||
|
@ -433,6 +434,7 @@ bool FramelessHelperWin::nativeEventFilter(const QByteArray &eventType, void *me
|
|||
qWarning() << "timeEndPeriod() failed.";
|
||||
break;
|
||||
}
|
||||
}
|
||||
// We cannot return WVR_REDRAW otherwise Windows exhibits bugs where
|
||||
// client pixels and child windows are mispositioned by the width/height
|
||||
// of the upper-left nonclient area.
|
||||
|
|
Loading…
Reference in New Issue