summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShawn Rutledge <shawn.rutledge@digia.com>2015-06-16 15:25:09 +0200
committerShawn Rutledge <shawn.rutledge@theqtcompany.com>2015-06-26 15:33:11 +0000
commitb5e1cd9954ec5bd64806cb1ae8a6abcd6275f945 (patch)
tree61036da186c9f61dfcc203c3927af660b86fe3db
parent1da6b79cd15bf91850d867a0783ddbf0cac36061 (diff)
downloadqtquickcontrols-b5e1cd9954ec5bd64806cb1ae8a6abcd6275f945.tar.gz
FileDialog: ensure that options are set early enough
A QPlatformFileDialogHelper with null options should never be allowed, otherwise a crash is possible. Task-number: QTBUG-46688 Change-Id: Ibe452876d38c0ca3b1b30560f06f837f7ac860b1 Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@theqtcompany.com>
-rw-r--r--src/dialogs/qquickplatformfiledialog.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/dialogs/qquickplatformfiledialog.cpp b/src/dialogs/qquickplatformfiledialog.cpp
index afab95fb..ab9ba72d 100644
--- a/src/dialogs/qquickplatformfiledialog.cpp
+++ b/src/dialogs/qquickplatformfiledialog.cpp
@@ -209,6 +209,7 @@ QPlatformFileDialogHelper *QQuickPlatformFileDialog::helper()
->createPlatformDialogHelper(QPlatformTheme::FileDialog));
if (!m_dlgHelper)
return m_dlgHelper;
+ m_dlgHelper->setOptions(m_options);
connect(m_dlgHelper, SIGNAL(directoryEntered(QUrl)), this, SIGNAL(folderChanged()));
connect(m_dlgHelper, SIGNAL(filterSelected(QString)), this, SIGNAL(filterSelected()));
connect(m_dlgHelper, SIGNAL(accept()), this, SLOT(accept()));