summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorCarlos Manuel Duclos Vergara <carlos.duclos@nokia.com>2010-05-14 15:55:48 +0200
committerCarlos Manuel Duclos Vergara <carlos.duclos@nokia.com>2010-05-14 16:16:38 +0200
commit92ea8a1df59cb00178cd7670d2ce167bba3dd953 (patch)
tree6445d956d348bcb5519e23f9a3c4c563a0e08d4f /src
parentb8f1d7fd87985375a373ca85052c475241822b03 (diff)
Fix for autotest failure in qwidget::saveRestoreGeometry()
The problem was that the fix for bug QTBUG-10519 introduced a new state for saving the geometry. However there is an exception and that exception comes into play when saving a maximized window. This fixes that by making sure we only enter into that state when the window is not currently maximized. Reviewed-by: tbastian
Diffstat (limited to 'src')
-rw-r--r--src/gui/kernel/qwidget.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/kernel/qwidget.cpp b/src/gui/kernel/qwidget.cpp
index 82eb12b04c..1f2cd8c692 100644
--- a/src/gui/kernel/qwidget.cpp
+++ b/src/gui/kernel/qwidget.cpp
@@ -6731,7 +6731,7 @@ QByteArray QWidget::saveGeometry() const
Q_D(const QWidget);
QRect newFramePosition = frameGeometry();
QRect newNormalPosition = normalGeometry();
- if(d->topData()->wasMaximized) {
+ if(d->topData()->wasMaximized && !(windowState() & Qt::WindowMaximized)) {
// Change the starting position
newFramePosition.moveTo(0, 0);
newNormalPosition.moveTo(0, 0);