diff --git a/src/gui/kernel/qwindow.cpp b/src/gui/kernel/qwindow.cpp index 1e30e57baf2..7750c70ba1e 100644 --- a/src/gui/kernel/qwindow.cpp +++ b/src/gui/kernel/qwindow.cpp @@ -597,7 +597,10 @@ void QWindowPrivate::setMinOrMaxSize(QSize *oldSizeMember, const QSize &size, // resize window if current size is outside of min and max limits if (minimumSize.width() <= maximumSize.width() || minimumSize.height() <= maximumSize.height()) { - q->resize(q->geometry().size().expandedTo(minimumSize).boundedTo(maximumSize)); + const QSize currentSize = q->size(); + const QSize boundedSize = currentSize.expandedTo(minimumSize).boundedTo(maximumSize); + if (currentSize != boundedSize) + q->resize(boundedSize); } }