diff options
author | Leena Miettinen <riitta-leena.miettinen@theqtcompany.com> | 2015-07-29 13:55:05 +0200 |
---|---|---|
committer | Leena Miettinen <riitta-leena.miettinen@theqtcompany.com> | 2015-07-30 06:15:30 +0000 |
commit | 332d41d025b5e289821cf2bd81745471c76dce36 (patch) | |
tree | 14ad194af8422435818866da587bb7d242af77de /src/widgets/dialogs | |
parent | edb5f22b0a5f791728951bc77e272279e06b6ab6 (diff) |
Doc: QFileDialog::ShowDirsOnly not supported on Windows
The native Windows file dialog does not support displaying
files in the directory chooser.
Task-number: QTBUG-46982
Change-Id: Ib58f3d888df564d42044b81ad8e67b8aeae5f3c6
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Diffstat (limited to 'src/widgets/dialogs')
-rw-r--r-- | src/widgets/dialogs/qfiledialog.cpp | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/src/widgets/dialogs/qfiledialog.cpp b/src/widgets/dialogs/qfiledialog.cpp index d2666026bb..64e3f5069e 100644 --- a/src/widgets/dialogs/qfiledialog.cpp +++ b/src/widgets/dialogs/qfiledialog.cpp @@ -189,7 +189,9 @@ Q_GLOBAL_STATIC(QUrl, lastVisitedDir) \value AnyFile The name of a file, whether it exists or not. \value ExistingFile The name of a single existing file. \value Directory The name of a directory. Both files and - directories are displayed. + directories are displayed. However, the native Windows + file dialog does not support displaying files in the + directory chooser. \value ExistingFiles The names of zero or more existing files. This value is obsolete since Qt 4.5: @@ -2388,9 +2390,12 @@ QUrl QFileDialog::getSaveFileUrl(QWidget *parent, pass. To ensure a native file dialog, \l{QFileDialog::}{ShowDirsOnly} must be set. - On Windows, and OS X, this static function will use the - native file dialog and not a QFileDialog. On Windows CE, if the device has - no native file dialog, a QFileDialog will be used. + On Windows and OS X, this static function will use the + native file dialog and not a QFileDialog. However, the native Windows file + dialog does not support displaying files in the directory chooser. You need + to pass \l{QFileDialog::}{DontUseNativeDialog} to display files using a + QFileDialog. On Windows CE, if the device has no native file dialog, a + QFileDialog will be used. On Unix/X11, the normal behavior of the file dialog is to resolve and follow symlinks. For example, if \c{/usr/tmp} is a symlink to \c{/var/tmp}, @@ -2398,7 +2403,7 @@ QUrl QFileDialog::getSaveFileUrl(QWidget *parent, \a options includes DontResolveSymlinks, the file dialog will treat symlinks as regular directories. - On Windows the dialog will spin a blocking modal event loop that will not + On Windows, the dialog will spin a blocking modal event loop that will not dispatch any QTimers, and if \a parent is not 0 then it will position the dialog just below the parent's title bar. |