┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/views
diff options
context:
space:
mode:
authorJin Liu <[email protected]>2024-03-12 09:43:44 +0000
committerMéven Car <[email protected]>2024-03-12 09:43:44 +0000
commit3a03f86b836e172001120ee73956a7bad9c7276b (patch)
tree66df355db80d59f84e3952a06ae945e1de1688eb /src/views
parentaf91586e00ceadcb7517f41067d97a8d0a2d385b (diff)
Enable custom view properties for special folders even if "remember for each folder" is off
Special folders include: search, trash, recents, timeline Not including Downloads, although we have a custom view when "remember for each folder" is on. Rational: These folders really need the custom view. So even if the user selects a global view for all "normal" folders, s/he probably still want a custom view for special folders.
Diffstat (limited to 'src/views')
-rw-r--r--src/views/viewproperties.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/views/viewproperties.cpp b/src/views/viewproperties.cpp
index f42adbce7..46ec2c28c 100644
--- a/src/views/viewproperties.cpp
+++ b/src/views/viewproperties.cpp
@@ -46,9 +46,7 @@ ViewProperties::ViewProperties(const QUrl &url)
// We try and save it to the file .directory in the directory being viewed.
// If the directory is not writable by the user or the directory is not local,
// we store the properties information in a local file.
- if (useGlobalViewProps) {
- m_filePath = destinationDir(QStringLiteral("global"));
- } else if (url.scheme().contains(QLatin1String("search"))) {
+ if (url.scheme().contains(QLatin1String("search"))) {
m_filePath = destinationDir(QStringLiteral("search/")) + directoryHashForUrl(url);
useSearchView = true;
} else if (url.scheme() == QLatin1String("trash")) {
@@ -63,6 +61,8 @@ ViewProperties::ViewProperties(const QUrl &url)
} else if (url.scheme() == QLatin1String("timeline")) {
m_filePath = destinationDir(QStringLiteral("timeline"));
useRecentDocumentsView = true;
+ } else if (useGlobalViewProps) {
+ m_filePath = destinationDir(QStringLiteral("global"));
} else if (url.isLocalFile()) {
m_filePath = url.toLocalFile();