From d9b7b0f1598be85e15bf85d0e955f5f379e28945 Mon Sep 17 00:00:00 2001 From: Andy Shaw Date: Mon, 18 May 2020 14:04:30 +0200 Subject: [PATCH] Windows: Update the hasFrame setting when changing window flags Since changing the window flags can make it frameless or have a frame then it should ensure that the hasFrame setting is updated accordingly when the window flags do. Change-Id: I7bf4995d7967623b117426d8750e63fa97967e2c Fixes: QTBUG-84029 Reviewed-by: Friedemann Kleint (cherry picked from commit 60ec350bc79d562c0611bc31e8655729272c31d6) Reviewed-by: Qt Cherry-pick Bot --- src/plugins/platforms/windows/qwindowswindow.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/src/plugins/platforms/windows/qwindowswindow.cpp b/src/plugins/platforms/windows/qwindowswindow.cpp index b3a8c145d29..adf0f918caa 100644 --- a/src/plugins/platforms/windows/qwindowswindow.cpp +++ b/src/plugins/platforms/windows/qwindowswindow.cpp @@ -2075,6 +2075,7 @@ QWindowsWindowData QWindowsWindow::setWindowFlags_sys(Qt::WindowFlags wt, QWindowsWindowData result = m_data; result.flags = creationData.flags; result.embedded = creationData.embedded; + result.hasFrame = (creationData.style & (WS_DLGFRAME | WS_THICKFRAME)); return result; }