┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/panels/terminal
diff options
context:
space:
mode:
authorLukáš Tinkl <[email protected]>2014-10-21 21:18:43 +0200
committerLukáš Tinkl <[email protected]>2014-10-21 21:19:14 +0200
commit1b4572dac9fb529d31b786f93e4f02c6f8aeeb21 (patch)
treecf88750183dbc93db5357be4a359c421c29d049c /src/panels/terminal
parent3653c8ad6bfb21a4b098f4e89d5ff34ed6df2901 (diff)
port Dolphin from KUrl to QUrl
REVIEW: 120688
Diffstat (limited to 'src/panels/terminal')
-rw-r--r--src/panels/terminal/terminalpanel.cpp9
-rw-r--r--src/panels/terminal/terminalpanel.h4
2 files changed, 6 insertions, 7 deletions
diff --git a/src/panels/terminal/terminalpanel.cpp b/src/panels/terminal/terminalpanel.cpp
index 964479628..02489d40e 100644
--- a/src/panels/terminal/terminalpanel.cpp
+++ b/src/panels/terminal/terminalpanel.cpp
@@ -127,7 +127,7 @@ void TerminalPanel::showEvent(QShowEvent* event)
Panel::showEvent(event);
}
-void TerminalPanel::changeDir(const KUrl& url)
+void TerminalPanel::changeDir(const QUrl& url)
{
delete m_mostLocalUrlJob;
m_mostLocalUrlJob = 0;
@@ -173,7 +173,7 @@ void TerminalPanel::sendCdToTerminal(const QString& dir)
void TerminalPanel::slotMostLocalUrlResult(KJob* job)
{
KIO::StatJob* statJob = static_cast<KIO::StatJob *>(job);
- const KUrl url = statJob->mostLocalUrl();
+ const QUrl url = statJob->mostLocalUrl();
if (url.isLocalFile()) {
sendCdToTerminal(url.toLocalFile());
}
@@ -188,10 +188,9 @@ void TerminalPanel::slotKonsolePartCurrentDirectoryChanged(const QString& dir)
// Only change the view URL if 'dir' is different from the current view URL.
// Note that the current view URL could also be a symbolic link to 'dir'
// -> use QDir::canonicalPath() to check that.
- const KUrl oldUrl(url());
- const KUrl newUrl(dir);
+ const QUrl oldUrl(url());
+ const QUrl newUrl(QUrl::fromLocalFile(dir));
if (newUrl != oldUrl && dir != QDir(oldUrl.path()).canonicalPath()) {
emit changeUrl(newUrl);
}
}
-
diff --git a/src/panels/terminal/terminalpanel.h b/src/panels/terminal/terminalpanel.h
index 6a0b38f5b..5d012a332 100644
--- a/src/panels/terminal/terminalpanel.h
+++ b/src/panels/terminal/terminalpanel.h
@@ -56,7 +56,7 @@ signals:
/**
* Is emitted if the an URL change is requested.
*/
- void changeUrl(const KUrl& url);
+ void changeUrl(const QUrl& url);
protected:
/** @see Panel::urlChanged() */
@@ -70,7 +70,7 @@ private slots:
void slotKonsolePartCurrentDirectoryChanged(const QString& dir);
private:
- void changeDir(const KUrl& url);
+ void changeDir(const QUrl& url);
void sendCdToTerminal(const QString& path);
private: