diff options
author | Alexis Menard <alexis.menard@nokia.com> | 2009-04-20 10:32:31 (GMT) |
---|---|---|
committer | Alexis Menard <alexis.menard@nokia.com> | 2009-04-20 10:37:07 (GMT) |
commit | 2e3f7621d696bec6173810c75b042249645fa714 (patch) | |
tree | b505e35c7f20de039d2b3dca2edfef72ee8f9484 /src/gui/dialogs/qfiledialog.cpp | |
parent | 0b15f59c648633357e9263e93c688e5462e3e01e (diff) | |
download | Qt-2e3f7621d696bec6173810c75b042249645fa714.zip Qt-2e3f7621d696bec6173810c75b042249645fa714.tar.gz Qt-2e3f7621d696bec6173810c75b042249645fa714.tar.bz2 |
This fix a bug on the QFileSystemModel with a custom icon provider
We were calling the provider with invalid path, with the default one it
fallback to all standard icons but with a custom one we call a public
method with an invalid QFileInfo. It was happening on windows only
for the My Drives view because in that case the parent path is null, my
Drives is a logical view.
Task-number: 251295
Reviewed-by: jasplin
Diffstat (limited to 'src/gui/dialogs/qfiledialog.cpp')
-rw-r--r-- | src/gui/dialogs/qfiledialog.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/gui/dialogs/qfiledialog.cpp b/src/gui/dialogs/qfiledialog.cpp index f70669c..9935a80 100644 --- a/src/gui/dialogs/qfiledialog.cpp +++ b/src/gui/dialogs/qfiledialog.cpp @@ -1437,6 +1437,8 @@ void QFileDialog::setIconProvider(QFileIconProvider *provider) { Q_D(QFileDialog); d->model->setIconProvider(provider); + //It forces the refresh of all entries in the side bar, then we can get new icons + d->qFileDialogUi->sidebar->setUrls(d->qFileDialogUi->sidebar->urls()); } /*! |