diff options
-rw-r--r-- | src/plugins/platforms/windows/qwindowswindow.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/plugins/platforms/windows/qwindowswindow.cpp b/src/plugins/platforms/windows/qwindowswindow.cpp index 16c2e16d64..402009c70d 100644 --- a/src/plugins/platforms/windows/qwindowswindow.cpp +++ b/src/plugins/platforms/windows/qwindowswindow.cpp @@ -66,6 +66,7 @@ #include <qpa/qwindowsysteminterface.h> #include <QtCore/QDebug> +#include <QtCore/QLibraryInfo> #include <dwmapi.h> @@ -1473,7 +1474,7 @@ void QWindowsWindow::setGeometry(const QRect &rectIn) // achieve that size (for example, window title minimal constraint), // notify and warn. setGeometry_sys(rect); - if (m_data.geometry != rect) { + if (m_data.geometry != rect && (isVisible() || QLibraryInfo::isDebugBuild())) { qWarning("%s: Unable to set geometry %dx%d+%d+%d on %s/'%s'." " Resulting geometry: %dx%d+%d+%d " "(frame: %d, %d, %d, %d, custom margin: %d, %d, %d, %d" |