Doc: update QFileDialog::setSideBarUrls code snippet

The example code uses QDesktopServices::storageLocation which has been
replaced by QStandardPaths. This patch fixes this.

Change-Id: Ifff25fcb9d85b37ef8247cb4cd9c4c1c8d368780
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
This commit is contained in:
Samuel Gaist 2015-08-21 01:10:53 +02:00
parent 63cf5d3d26
commit 8a0be4007d
2 changed files with 2 additions and 2 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 28 KiB

After

Width:  |  Height:  |  Size: 26 KiB

View File

@ -46,8 +46,8 @@ int main(int argv, char **args)
//![0]
QList<QUrl> urls;
urls << QUrl::fromLocalFile("/home/gvatteka/dev/qt-45")
<< QUrl::fromLocalFile(QDesktopServices::storageLocation(QDesktopServices::MusicLocation));
urls << QUrl::fromLocalFile("/Users/foo/Code/qt5")
<< QUrl::fromLocalFile(QStandardPaths::standardLocations(QStandardPaths::MusicLocation).first());
QFileDialog dialog;
dialog.setSidebarUrls(urls);