3 #include <QDesktopServices>
23 QUrl url(QStringLiteral(
"file://"));
28 tmp.replace(QChar(
'\\'), QChar(
'/'));
31 if (QFileInfo(path).isAbsolute()) {
32 tmp = QStringLiteral(
"/") + tmp;
34 url.setPath(tmp, QUrl::DecodedMode);
37 url.setPath(path, QUrl::DecodedMode);
39 return QDesktopServices::openUrl(url);