diff options
author | Pasi Matilainen <pasi.matilainen@digia.com> | 2012-02-27 10:19:47 (GMT) |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-02-28 01:05:44 (GMT) |
commit | 3165fe0d809e25177dd0b91964f7d0718922121e (patch) | |
tree | fb742e955e8527f8f725160b59bb9854b5888010 /src/gui/dialogs | |
parent | c366377fa6a6fb39679a2f5d4a2c5063e82c91b2 (diff) | |
download | Qt-3165fe0d809e25177dd0b91964f7d0718922121e.zip Qt-3165fe0d809e25177dd0b91964f7d0718922121e.tar.gz Qt-3165fe0d809e25177dd0b91964f7d0718922121e.tar.bz2 |
Fix modal file dialog opening on Mac
When a modal file dialog is opened on Mac, the native file dialog is
actually opened twice, first as modeless and later as modal. Normally
this works (by chance), but when the application runs in a sandbox,
this results in a crash.
Task-number: QTBUG-21609
Change-Id: I906868e1b4bd74dc3030891bede51f32ebd16b4a
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
Diffstat (limited to 'src/gui/dialogs')
-rw-r--r-- | src/gui/dialogs/qfiledialog_mac.mm | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/dialogs/qfiledialog_mac.mm b/src/gui/dialogs/qfiledialog_mac.mm index 05f717e..a858aa7 100644 --- a/src/gui/dialogs/qfiledialog_mac.mm +++ b/src/gui/dialogs/qfiledialog_mac.mm @@ -1082,7 +1082,7 @@ bool QFileDialogPrivate::showCocoaFilePanel() QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate) *delegate = static_cast<QT_MANGLE_NAMESPACE(QNSOpenSavePanelDelegate) *>(mDelegate); if (qt_mac_is_macsheet(q)) [delegate showWindowModalSheet:q->parentWidget()]; - else + else if (!q->testAttribute(Qt::WA_ShowModal)) [delegate showModelessPanel]; return true; } |