parent
416f717834
commit
19279aa848
|
@ -1002,12 +1002,14 @@ qreal WinNativeEventFilter::getPreferedNumber(qreal num) {
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
void WinNativeEventFilter::updateWindow(HWND handle) {
|
void WinNativeEventFilter::updateWindow(HWND handle, bool triggerFrameChange) {
|
||||||
initWin32Api();
|
initWin32Api();
|
||||||
if (handle && m_lpIsWindow(handle)) {
|
if (handle && m_lpIsWindow(handle)) {
|
||||||
m_lpSetWindowPos(handle, nullptr, 0, 0, 0, 0,
|
if (triggerFrameChange) {
|
||||||
SWP_FRAMECHANGED | SWP_NOACTIVATE | SWP_NOSIZE |
|
m_lpSetWindowPos(handle, nullptr, 0, 0, 0, 0,
|
||||||
SWP_NOMOVE | SWP_NOZORDER | SWP_NOOWNERZORDER);
|
SWP_FRAMECHANGED | SWP_NOACTIVATE | SWP_NOSIZE |
|
||||||
|
SWP_NOMOVE | SWP_NOZORDER | SWP_NOOWNERZORDER);
|
||||||
|
}
|
||||||
m_lpRedrawWindow(handle, nullptr, nullptr,
|
m_lpRedrawWindow(handle, nullptr, nullptr,
|
||||||
RDW_INVALIDATE | RDW_UPDATENOW | RDW_NOCHILDREN);
|
RDW_INVALIDATE | RDW_UPDATENOW | RDW_NOCHILDREN);
|
||||||
}
|
}
|
||||||
|
|
|
@ -94,7 +94,7 @@ public:
|
||||||
// window (if the pointer is null, return the system's standard value).
|
// window (if the pointer is null, return the system's standard value).
|
||||||
static int titlebarHeight(HWND handle);
|
static int titlebarHeight(HWND handle);
|
||||||
|
|
||||||
static void updateWindow(HWND handle);
|
static void updateWindow(HWND handle, bool triggerFrameChange = true);
|
||||||
|
|
||||||
#if (QT_VERSION >= QT_VERSION_CHECK(6, 0, 0))
|
#if (QT_VERSION >= QT_VERSION_CHECK(6, 0, 0))
|
||||||
bool nativeEventFilter(const QByteArray &eventType, void *message,
|
bool nativeEventFilter(const QByteArray &eventType, void *message,
|
||||||
|
|
Loading…
Reference in New Issue