┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/views/dolphinmodel.cpp
diff options
context:
space:
mode:
authorPeter Penz <[email protected]>2010-11-18 16:18:07 +0000
committerPeter Penz <[email protected]>2010-11-18 16:18:07 +0000
commit9a189645cc4218e0efe5a718a4ac46ed006e6512 (patch)
tree59d2570e777756122b141fedfeb84ce93bb13b27 /src/views/dolphinmodel.cpp
parent9e29e6426b149e05ab61b39f1969513c358fc1e7 (diff)
- When showing the trash content, use the details view with path as default view
- Assure that the original path is shown for the trash protocol within Dolphin svn path=/trunk/KDE/kdebase/apps/; revision=1198481
Diffstat (limited to 'src/views/dolphinmodel.cpp')
-rw-r--r--src/views/dolphinmodel.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/views/dolphinmodel.cpp b/src/views/dolphinmodel.cpp
index 5e62881a8..6474a4f3c 100644
--- a/src/views/dolphinmodel.cpp
+++ b/src/views/dolphinmodel.cpp
@@ -104,7 +104,12 @@ QVariant DolphinModel::data(const QModelIndex& index, int role) const
case DolphinModel::LocalPathOrUrl:
const KDirModel *dirModel = qobject_cast<const KDirModel*>(index.model());
const KFileItem item = dirModel->itemForIndex(index);
- return item.mostLocalUrl().directory();
+ const KUrl url = item.mostLocalUrl();
+ if (url.protocol() == QLatin1String("trash")) {
+ const KIO::UDSEntry udsEntry = item.entry();
+ return udsEntry.stringValue(KIO::UDSEntry::UDS_EXTRA);
+ }
+ return url.directory();
}
break;