┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPiotr Henryk Dabrowski <[email protected]>2019-12-21 12:27:41 -0700
committerNate Graham <[email protected]>2019-12-21 12:28:06 -0700
commit6cb4d81a02e1d11d8946e9d723cb6814e62c27c9 (patch)
tree6210fe344bcf3e38123c510007066c6dd8c33627
parent080498368502bfbdc4e13427ba3a9a21cefcafdf (diff)
Use KParts::ReadOnlyPart::localFilePath() in DolphinPart::slotOpenTerminal()
Reviewers: ngraham, elvisangelaccio, #dolphin Reviewed By: ngraham, elvisangelaccio, #dolphin Subscribers: kfm-devel Tags: #dolphin Differential Revision: https://phabricator.kde.org/D26140
-rw-r--r--src/dolphinpart.cpp18
1 files changed, 1 insertions, 17 deletions
diff --git a/src/dolphinpart.cpp b/src/dolphinpart.cpp
index edf58f565..7e7425121 100644
--- a/src/dolphinpart.cpp
+++ b/src/dolphinpart.cpp
@@ -533,23 +533,7 @@ void DolphinPart::setNameFilter(const QString& nameFilter)
void DolphinPart::slotOpenTerminal()
{
- QString dir(QDir::homePath());
-
- QUrl u(url());
-
- // If the given directory is not local, it can still be the URL of an
- // ioslave using UDS_LOCAL_PATH which to be converted first.
- KIO::StatJob* statJob = KIO::mostLocalUrl(u);
- KJobWidgets::setWindow(statJob, widget());
- statJob->exec();
- u = statJob->mostLocalUrl();
-
- //If the URL is local after the above conversion, set the directory.
- if (u.isLocalFile()) {
- dir = u.toLocalFile();
- }
-
- KToolInvocation::invokeTerminal(QString(), dir);
+ KToolInvocation::invokeTerminal(QString(), KParts::ReadOnlyPart::localFilePath());
}
void DolphinPart::slotFindFile()