┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/kitemviews/kfileitemmodel.cpp2
-rw-r--r--src/views/viewproperties.cpp12
2 files changed, 7 insertions, 7 deletions
diff --git a/src/kitemviews/kfileitemmodel.cpp b/src/kitemviews/kfileitemmodel.cpp
index 7ea5e8018..f6b51f21c 100644
--- a/src/kitemviews/kfileitemmodel.cpp
+++ b/src/kitemviews/kfileitemmodel.cpp
@@ -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);
diff --git a/src/views/viewproperties.cpp b/src/views/viewproperties.cpp
index 30deb7277..d4ecfafa0 100644
--- a/src/views/viewproperties.cpp
+++ b/src/views/viewproperties.cpp
@@ -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;
}
}