mirror of
https://invent.kde.org/network/falkon.git
synced 2024-11-11 09:32:12 +01:00
Merge pull request #510 from srazi/master
Select downloaded file when opening its folder [Windows only]
This commit is contained in:
commit
1ff2f975bb
|
@ -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()
|
||||
|
|
Loading…
Reference in New Issue
Block a user