#include "statusbar/dolphinstatusbar.h"
#include "views/dolphinviewactionhandler.h"
#include "views/dolphinremoteencoding.h"
+#include "views/draganddrophelper.h"
#include "views/viewproperties.h"
#ifndef Q_OS_WIN
actionCollection()->action("close_tab")->setEnabled(true);
- // provide a split view, if the startup settings are set this way
+ // Provide a split view, if the startup settings are set this way
if (GeneralSettings::splitView()) {
const int newTabIndex = m_viewTab.count() - 1;
createSecondaryView(newTabIndex);
- viewTab.secondaryView->setActive(true);
- viewTab.isPrimaryViewActive = false;
+ m_viewTab[newTabIndex].secondaryView->setActive(true);
+ m_viewTab[newTabIndex].isPrimaryViewActive = false;
}
if (focusWidget) {
const KUrl::List urls = KUrl::List::fromMimeData(event->mimeData());
if (!urls.isEmpty() && tab != -1) {
const ViewTab& viewTab = m_viewTab[tab];
- const KUrl destPath = viewTab.isPrimaryViewActive ? viewTab.primaryView->url() : viewTab.secondaryView->url();
- Q_UNUSED(destPath);
- //DragAndDropHelper::instance().dropUrls(KFileItem(), destPath, event, m_tabBar);
+ const DolphinView* view = viewTab.isPrimaryViewActive ? viewTab.primaryView->view()
+ : viewTab.secondaryView->view();
+ DragAndDropHelper::dropUrls(view->rootItem(), event);
}
}