]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/dolphinview.cpp
* Move code from DolphinDropController to DragAndDropHelper.
[dolphin.git] / src / dolphinview.cpp
index d0e1b8bd24bb4b78b7c1798342e6509c83639731..cd9b67bb7725a1e4857c79f3f47e4c8167c426a2 100644 (file)
@@ -47,7 +47,6 @@
 #include <ktoggleaction.h>
 #include <kurl.h>
 
-#include "dolphindropcontroller.h"
 #include "dolphinmodel.h"
 #include "dolphincolumnview.h"
 #include "dolphincontroller.h"
@@ -58,6 +57,7 @@
 #include "dolphiniconsview.h"
 #include "dolphinsettings.h"
 #include "dolphin_generalsettings.h"
+#include "draganddrophelper.h"
 #include "folderexpander.h"
 #include "renamedialog.h"
 #include "tooltipmanager.h"
@@ -126,7 +126,7 @@ DolphinView::DolphinView(QWidget* parent,
             this, SLOT(clearHoverInformation()));
 
     connect(m_dirLister, SIGNAL(redirection(KUrl, KUrl)),
-            this, SLOT(slotRedirection(KUrl, KUrl)));
+            this, SIGNAL(redirection(KUrl, KUrl)));
     connect(m_dirLister, SIGNAL(completed()),
             this, SLOT(restoreCurrentItem()));
 
@@ -871,7 +871,7 @@ void DolphinView::dropUrls(const KFileItem& destItem,
                            const KUrl& destPath,
                            QDropEvent* event)
 {
-    DolphinDropController::dropUrls(destItem, destPath, event, this);
+    DragAndDropHelper::dropUrls(destItem, destPath, event, this);
 }
 
 void DolphinView::updateSorting(DolphinView::Sorting sorting)
@@ -1027,13 +1027,6 @@ void DolphinView::slotDeleteFileFinished(KJob* job)
     }
 }
 
-void DolphinView::slotRedirection(const KUrl& oldUrl, const KUrl& newUrl)
-{
-    if (oldUrl == m_controller->url()) {
-        m_controller->setUrl(newUrl);
-    }
-}
-
 void DolphinView::slotRequestUrlChange(const KUrl& url)
 {
     emit requestUrlChange(url);
@@ -1232,6 +1225,8 @@ void DolphinView::createView()
 
     if (DolphinSettings::instance().generalSettings()->showToolTips()) {
         m_toolTipManager = new ToolTipManager(view, m_proxyModel);
+        connect(m_controller, SIGNAL(hideToolTip()),
+                m_toolTipManager, SLOT(hideTip()));
     }
 
     m_topLayout->insertWidget(1, view);