]> cloud.milkyroute.net Git - dolphin.git/commitdiff
Revert the whole code regarding the discussed issue. Columns view still show the...
authorRafael Fernández López <ereslibre@kde.org>
Tue, 18 Dec 2007 20:53:49 +0000 (20:53 +0000)
committerRafael Fernández López <ereslibre@kde.org>
Tue, 18 Dec 2007 20:53:49 +0000 (20:53 +0000)
files too... so something needs a fix here. Shouldn't be hard anyway

CCMAIL: peter.penz@gmx.at
CCMAIL: faure@kde.org

svn path=/trunk/KDE/kdebase/apps/; revision=750168

src/dolphincolumnwidget.cpp
src/dolphindetailsview.cpp
src/dolphiniconsview.cpp

index ab7945ea721099278bbd23a26d6a8c3e9e583a12..9a500df6b379f234e198256c97aebaf4a24e1cc1 100644 (file)
@@ -247,20 +247,6 @@ void DolphinColumnWidget::dragMoveEvent(QDragMoveEvent* event)
         }
     }
     setDirtyRegion(m_dropRect);
-
-    bool destIsDir = false;
-    if (index.isValid()) {
-        const KFileItem item = itemForIndex(index);
-        if (!item.isNull() && item.isDir()) {
-            m_dropRect = visualRect(index);
-            destIsDir = true;
-        }
-    } else { // dropping on viewport
-        destIsDir = true;
-    }
-    if (destIsDir && event->mimeData()->hasUrls()) {
-        event->acceptProposedAction();
-    }
 }
 
 void DolphinColumnWidget::dropEvent(QDropEvent* event)
index f58b4cd1e2545090b27c5ae45645b74d624f3f10..46752fc95a39870bac6a84256d8cded1678ee1dc 100644 (file)
@@ -278,20 +278,6 @@ void DolphinDetailsView::dragMoveEvent(QDragMoveEvent* event)
         }
         setDirtyRegion(m_dropRect);
     }
-
-    bool destIsDir = false;
-    if (index.isValid()) {
-        const KFileItem item = itemForIndex(index);
-        if (!item.isNull() && item.isDir()) {
-            m_dropRect = visualRect(index);
-            destIsDir = true;
-        }
-    } else { // dropping on viewport
-        destIsDir = true;
-    }
-    if (destIsDir && event->mimeData()->hasUrls()) {
-        event->acceptProposedAction();
-    }
 }
 
 void DolphinDetailsView::dropEvent(QDropEvent* event)
index 8d474f4bc5f15fe2b44b6ba94f6e4447c1170ef6..05b8ed9cc16a88bb468ecb3c37784a0115841979 100644 (file)
@@ -225,17 +225,14 @@ void DolphinIconsView::dragMoveEvent(QDragMoveEvent* event)
     setDirtyRegion(m_dropRect);
 
     m_dropRect.setSize(QSize()); // set as invalid
-    bool destIsDir = false;
     if (index.isValid()) {
         const KFileItem item = itemForIndex(index);
-        if (!item.isNull() && item.isDir()) {
+        if (!item.isNull()) {
             m_dropRect = visualRect(index);
-            destIsDir = true;
         }
-    } else { // dropping on viewport
-        destIsDir = true;
     }
-    if (destIsDir && event->mimeData()->hasUrls()) {
+    if (event->mimeData()->hasUrls()) {
+        // accept url drops, independently from the destination item
         event->acceptProposedAction();
     }