summaryrefslogtreecommitdiffstats
path: root/src/plugins
diff options
context:
space:
mode:
authorAndy Shaw <andy.shaw@digia.com>2015-02-12 09:19:25 +0100
committerAndy Shaw <andy.shaw@digia.com>2015-02-16 14:59:22 +0000
commitcbece1e8c471322b0650dfb2a3f7b2258ff4c1c9 (patch)
tree92e5d09b17844ca32cf0481f36c92f02aa409136 /src/plugins
parent76de1ac0a4cd384f608a14b5d77a8cf3ef1ec868 (diff)
Ensure the filedialog shows the initial filename
Whenever the selection changes it will call panelSelectionDidChange even if the panel is not visible which causes it to overwrite our chosen initial file with "untitled". Therefore we only set the name when the panel is actually visible. Change-Id: I09f7ebabce5c2139a7f74b953391d39dfad65db2 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm b/src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm
index 084b53af79..bec5602934 100644
--- a/src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm
+++ b/src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm
@@ -446,7 +446,7 @@ static QString strippedText(QString s)
- (void)panelSelectionDidChange:(id)sender
{
Q_UNUSED(sender);
- if (mHelper) {
+ if (mHelper && [mSavePanel isVisible]) {
QString selection = QCFString::toQString([[mSavePanel URL] path]);
if (selection != mCurrentSelection) {
*mCurrentSelection = selection;