From b0211b09c934dd8463fdd6b3683de64d487392db Mon Sep 17 00:00:00 2001 From: Roman Telezhynskyi Date: Sun, 29 Nov 2015 14:03:35 +0200 Subject: [PATCH] Resolved issue #403. Tape - Button "Show in Explorer" is not working. --HG-- branch : develop --- src/app/tape/tmainwindow.cpp | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/src/app/tape/tmainwindow.cpp b/src/app/tape/tmainwindow.cpp index e32002045..3779ed292 100644 --- a/src/app/tape/tmainwindow.cpp +++ b/src/app/tape/tmainwindow.cpp @@ -2684,7 +2684,7 @@ void TMainWindow::InitGender(QComboBox *gender) //--------------------------------------------------------------------------------------------------------------------- void TMainWindow::ShowInGraphicalShell() { -#ifdef Q_WS_MAC +#ifdef Q_OS_MAC QStringList args; args << "-e"; args << "tell application \"Finder\""; @@ -2695,11 +2695,8 @@ void TMainWindow::ShowInGraphicalShell() args << "-e"; args << "end tell"; QProcess::startDetached("osascript", args); -#elif defined(Q_WS_WIN) - QStringList args; - args << "/select," << QDir::toNativeSeparators(curFile); - const QString command = "explorer" + " " + args; - QProcess::startDetached(command); +#elif defined(Q_OS_WIN) + QProcess::startDetached(QString("explorer /select, \"%1\"").arg(QDir::toNativeSeparators(curFile))); #else const QString app = "xdg-open %d"; QString cmd;