-void ConfigurePreviewPluginDialog::slotOk()
-{
- m_previewPlugin->writeConfiguration(m_configurationWidget);
- // TODO: It would be great having a mechanism to tell PreviewJob that only previews
- // for a specific MIME-type should be regenerated. As this is not available yet we
- // delete the whole thumbnails directory.
- QApplication::changeOverrideCursor(Qt::BusyCursor);
- KIO::NetAccess::del(QUrl::fromLocalFile(QDir::homePath() + "/.thumbnails/"), this);
- QApplication::restoreOverrideCursor();
-}
+ // http://specifications.freedesktop.org/thumbnail-spec/thumbnail-spec-latest.html#DIRECTORY
+ const QString thumbnailsPath = QStandardPaths::writableLocation(QStandardPaths::GenericCacheLocation) + QLatin1String("/thumbnails/");
+ KIO::del(QUrl::fromLocalFile(thumbnailsPath), KIO::HideProgressInfo);
+ });
+ }
+}
\ No newline at end of file