summaryrefslogtreecommitdiffstats
path: root/src/gui/dialogs
diff options
context:
space:
mode:
authorGareth Stockwell <ext-gareth.stockwell@nokia.com>2011-12-13 12:24:14 +0000
committerGareth Stockwell <ext-gareth.stockwell@nokia.com>2011-12-13 12:33:03 +0000
commitb249e4c32d697ef56c196bb2a14a18319100f127 (patch)
treeb26306c03a3304dd36c88560b683046b4e4abeb4 /src/gui/dialogs
parent43d4faf686da7d553171d7c8894c2825b4572dd6 (diff)
Default to QDir::homePath() in Symbian native file dialogs
Symbian places restrictions on the directories in which the native file dialog can browse. If the path passed to QFileDialog::getXxxFileName() is inaccessible, the implementation defaults to a path which is accessible. Previously, this default path was QDir::rootPath(). Changes to the Symbian file engine in Qt 4.8 mean that this now returns "C:\" which is inaccesible to the file dialog. This patch changes the default path to QDir::homePath(), which returns "C:\data". Task-number: ou1cimx1#947939 Reviewed-by: Miikka Heikkinen
Diffstat (limited to 'src/gui/dialogs')
-rw-r--r--src/gui/dialogs/qfiledialog_symbian.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gui/dialogs/qfiledialog_symbian.cpp b/src/gui/dialogs/qfiledialog_symbian.cpp
index 1ffbf1dfe2..01c7b9b7db 100644
--- a/src/gui/dialogs/qfiledialog_symbian.cpp
+++ b/src/gui/dialogs/qfiledialog_symbian.cpp
@@ -143,8 +143,8 @@ static QString launchSymbianDialog(const QString dialogCaption, const QString st
tryCount = 0;
} else {
// Symbian native file dialog doesn't allow accessing files outside C:/Data
- // It will always leave in that case, so default into QDir::rootPath() in error cases.
- QString dir = QDir::toNativeSeparators(QDir::rootPath());
+ // It will always leave in that case, so default into QDir::homePath() in error cases.
+ QString dir = QDir::toNativeSeparators(QDir::homePath());
startFolder = qt_QString2TPtrC(dir);
}
}