summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qwidget_mac.mm
diff options
context:
space:
mode:
authorWater-Team <water@pad.test.qt.nokia.com>2011-06-29 21:42:03 (GMT)
committerWater-Team <water@pad.test.qt.nokia.com>2011-06-29 21:42:03 (GMT)
commit0a8daa8845325fba9cf2ec973eb6bab8a2853dd5 (patch)
tree504c698037ee6283f1b5dbc6fa658bb2bfffb99a /src/gui/kernel/qwidget_mac.mm
parent680023c4921019614948c277cde5498645836cb9 (diff)
parent6b3f2a3b96d01dc339d07a076300d29616603b28 (diff)
downloadQt-0a8daa8845325fba9cf2ec973eb6bab8a2853dd5.zip
Qt-0a8daa8845325fba9cf2ec973eb6bab8a2853dd5.tar.gz
Qt-0a8daa8845325fba9cf2ec973eb6bab8a2853dd5.tar.bz2
Merge branch '4.8-upstream' into master-water
Diffstat (limited to 'src/gui/kernel/qwidget_mac.mm')
-rw-r--r--src/gui/kernel/qwidget_mac.mm12
1 files changed, 5 insertions, 7 deletions
diff --git a/src/gui/kernel/qwidget_mac.mm b/src/gui/kernel/qwidget_mac.mm
index 225a296..a51e295 100644
--- a/src/gui/kernel/qwidget_mac.mm
+++ b/src/gui/kernel/qwidget_mac.mm
@@ -4554,6 +4554,11 @@ void QWidgetPrivate::setGeometry_sys_helper(int x, int y, int w, int h, bool isM
QPoint oldp = q->pos();
QSize olds = q->size();
+ // Apply size restrictions, applicable for Windows & Widgets.
+ if (QWExtra *extra = extraData()) {
+ w = qBound(extra->minw, w, extra->maxw);
+ h = qBound(extra->minh, h, extra->maxh);
+ }
const bool isResize = (olds != QSize(w, h));
if (!realWindow && !isResize && QPoint(x, y) == oldp)
@@ -4563,13 +4568,6 @@ void QWidgetPrivate::setGeometry_sys_helper(int x, int y, int w, int h, bool isM
data.window_state = data.window_state & ~Qt::WindowMaximized;
const bool visible = q->isVisible();
- // Apply size restrictions, applicable for Windows & Widgets.
- if (QWExtra *extra = extraData()) {
- w = qMin(w, extra->maxw);
- h = qMin(h, extra->maxh);
- w = qMax(w, extra->minw);
- h = qMax(h, extra->minh);
- }
data.crect = QRect(x, y, w, h);
if (realWindow) {