summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRichard Moe Gustavsen <richard.gustavsen@nokia.com>2010-01-04 14:45:49 (GMT)
committerRichard Moe Gustavsen <richard.gustavsen@nokia.com>2010-01-04 14:47:53 (GMT)
commit2176a58c5312e2f994d5e345708a3b37e333d668 (patch)
treeb79e5e4f3da2a796ce025152bed57a2d104d3cf0 /src
parent81d06f72cb84485847f963ba1dfea662e51096e4 (diff)
downloadQt-2176a58c5312e2f994d5e345708a3b37e333d668.zip
Qt-2176a58c5312e2f994d5e345708a3b37e333d668.tar.gz
Qt-2176a58c5312e2f994d5e345708a3b37e333d668.tar.bz2
Cocoa: exec() on a dialog with Qt::Tool windowflag is just a dialog.
This is because a modal flag on the window wins over the type when determining window class. This fix will respect the type first, before looking at the window flag. Task-number: QTBUG-1455 Reviewed-by: Prasanth
Diffstat (limited to 'src')
-rw-r--r--src/gui/kernel/qwidget_mac.mm6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/gui/kernel/qwidget_mac.mm b/src/gui/kernel/qwidget_mac.mm
index 3925905..35e7505 100644
--- a/src/gui/kernel/qwidget_mac.mm
+++ b/src/gui/kernel/qwidget_mac.mm
@@ -1888,13 +1888,15 @@ void QWidgetPrivate::determineWindowClass()
wclass = kDocumentWindowClass;
else if(popup || (QSysInfo::MacintoshVersion >= QSysInfo::MV_10_5 && type == Qt::SplashScreen))
wclass = kModalWindowClass;
- else if(q->testAttribute(Qt::WA_ShowModal) || type == Qt::Dialog)
+ else if(type == Qt::Dialog)
wclass = kMovableModalWindowClass;
else if(type == Qt::ToolTip)
wclass = kHelpWindowClass;
else if(type == Qt::Tool || (QSysInfo::MacintoshVersion < QSysInfo::MV_10_5
&& type == Qt::SplashScreen))
wclass = kFloatingWindowClass;
+ else if(q->testAttribute(Qt::WA_ShowModal))
+ wclass = kMovableModalWindowClass;
else
wclass = kDocumentWindowClass;
@@ -1998,8 +2000,6 @@ void QWidgetPrivate::determineWindowClass()
for(int i = 0; tmp_wattr && known_attribs[i].name; i++) {
if((tmp_wattr & known_attribs[i].tag) == known_attribs[i].tag) {
tmp_wattr ^= known_attribs[i].tag;
- qDebug("Qt: internal: * %s %s", known_attribs[i].name,
- (GetAvailableWindowAttributes(wclass) & known_attribs[i].tag) ? "" : "(*)");
}
}
if(tmp_wattr)