3 #include <QDesktopServices> 18 tmp.replace(QChar(
'\\'), QChar(
'/'));
19 QUrl url(QStringLiteral(
"file:///"));
20 url.setPath(tmp, QUrl::DecodedMode);
21 return QDesktopServices::openUrl(url);
23 QUrl url(QStringLiteral(
"file://"));
24 url.setPath(path, QUrl::DecodedMode);
25 return QDesktopServices::openUrl(url);
bool QT_UTILITIES_EXPORT openLocalFileOrDir(const QString &path)
Shows the specified file or directory using the default file browser.