]> cloud.milkyroute.net Git - dolphin.git/commitdiff
Merge remote-tracking branch 'origin/KDE/4.10'
authorFrank Reininghaus <frank78ac@googlemail.com>
Mon, 24 Jun 2013 20:02:04 +0000 (22:02 +0200)
committerFrank Reininghaus <frank78ac@googlemail.com>
Mon, 24 Jun 2013 20:02:04 +0000 (22:02 +0200)
src/kitemviews/kfileitemmodel.cpp
src/views/viewproperties.cpp

index 7ea5e8018265aabf6a0e00e13eee7e176128a7e5..f6b51f21c04f76bb618b5ec7a4553a82958dba95 100644 (file)
@@ -249,7 +249,7 @@ QMimeData* KFileItemModel::createMimeData(const QSet<int>& indexes) const
         const int index = it.next();
         const KFileItem item = fileItem(index);
         if (!item.isNull()) {
-            urls << item.url();
+            urls << item.targetUrl();
 
             bool isLocal;
             mostLocalUrls << item.mostLocalUrl(isLocal);
index 30deb7277dc0931a22eaeb6496b05e238a4a012a..d4ecfafa0822d49d867aa032fcd983545cf0465d 100644 (file)
@@ -53,7 +53,7 @@ ViewProperties::ViewProperties(const KUrl& url) :
     m_node(0)
 {
     GeneralSettings* settings = GeneralSettings::self();
-    const bool useGlobalViewProps = settings->globalViewProps();
+    const bool useGlobalViewProps = settings->globalViewProps() || url.isEmpty();
     bool useDetailsViewWithPath = false;
 
     // We try and save it to the file .directory in the directory being viewed.
@@ -100,13 +100,13 @@ ViewProperties::ViewProperties(const KUrl& url) :
             setVisibleRoles(QList<QByteArray>() << "path");
         } else {
             // The global view-properties act as default for directories without
-            // any view-property configuration
-            settings->setGlobalViewProps(true);
-
-            ViewProperties defaultProps(url);
+            // any view-property configuration. Constructing a ViewProperties 
+            // instance for an empty KUrl ensures that the global view-properties
+            // are loaded.
+            KUrl emptyUrl;
+            ViewProperties defaultProps(emptyUrl);
             setDirProperties(defaultProps);
 
-            settings->setGlobalViewProps(false);
             m_changedProps = false;
         }
     }