]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/urlnavigator.cpp
Get ride of the sidebar and use dockwidgets instead.
[dolphin.git] / src / urlnavigator.cpp
index 1f9295cb5fbfcb6129b3cfa9400eaa79bd9bd290..bc2c5914e3b0fd2808c0f14351dce6ed5c4131e2 100644 (file)
@@ -51,7 +51,7 @@
 #include <kvbox.h>
 
 #include "bookmarkselector.h"
-#include "dolphin.h"
+#include "dolphinmainwindow.h"
 #include "dolphinsettings.h"
 #include "dolphinstatusbar.h"
 #include "dolphinview.h"
@@ -203,7 +203,7 @@ KUrl UrlNavigator::url(int index) const
     QString path(url().pathOrUrl());
     path = path.section('/', 0, index);
 
-    if (path.at(path.length()) != '/')
+    if (path.at(path.length()-1) != '/')
     {
         path.append('/');
     }
@@ -470,9 +470,9 @@ void UrlNavigator::updateContent()
 
     QToolTip::remove(m_toggleButton);
     QString path(url().pathOrUrl());
-    const KAction* action = Dolphin::mainWin().actionCollection()->action("editable_location");
+    const KAction* action = dolphinView()->mainWindow()->actionCollection()->action("editable_location");
     // TODO: registry of default shortcuts
-    QString shortcut = action? action->shortcutText() : "Ctrl+L";
+    QString shortcut = action? action->shortcut().toString() : "Ctrl+L";
     if (m_toggleButton->isChecked()) {
         delete m_protocols; m_protocols = 0;
         delete m_protocolSeparator; m_protocolSeparator = 0;