1
mirror of https://invent.kde.org/network/falkon.git synced 2024-11-11 09:32:12 +01:00

[Windows only] Action 'Open Folder' in downoad manager opens folder and selects file.

This commit is contained in:
S. Razi Alavizadeh 2012-08-18 05:05:54 +04:30
parent e517b9ec65
commit 3d16d49aa5

View File

@ -33,6 +33,7 @@
#include <QFileInfo>
#include <QMessageBox>
#include <QDesktopServices>
#include <QProcess>
//#define DOWNMANAGER_DEBUG
@ -385,7 +386,13 @@ void DownloadItem::openFile()
void DownloadItem::openFolder()
{
#ifdef Q_WS_WIN
QString winFileName = m_path + m_fileName;
winFileName.replace("/","\\");
QProcess::startDetached("explorer.exe /e,/select,\""+winFileName+"\"");
#else
QDesktopServices::openUrl(QUrl::fromLocalFile(m_path));
#endif
}
void DownloadItem::readyRead()