31 lines
959 B
Diff
31 lines
959 B
Diff
From 7c3c6fadf6043408fd17167bab794f99ee61e7e4 Mon Sep 17 00:00:00 2001
|
|
From: liuzhilin <liuzhilin@uniontech.com>
|
|
Date: Wed, 27 Dec 2023 09:55:04 +0800
|
|
Subject: [PATCH] fix-dde-trash-error
|
|
|
|
---
|
|
plugins/trash/popupcontrolwidget.cpp | 3 ++-
|
|
1 file changed, 2 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/plugins/trash/popupcontrolwidget.cpp b/plugins/trash/popupcontrolwidget.cpp
|
|
index 77d3810a..d5ad0bba 100644
|
|
--- a/plugins/trash/popupcontrolwidget.cpp
|
|
+++ b/plugins/trash/popupcontrolwidget.cpp
|
|
@@ -14,11 +14,12 @@
|
|
#include <DDesktopServices>
|
|
|
|
#include <QCoreApplication>
|
|
+#include <QStandardPaths>
|
|
|
|
DWIDGET_USE_NAMESPACE
|
|
DCORE_USE_NAMESPACE
|
|
|
|
-const QString TrashDir = QDir::homePath() + "/.local/share/Trash";
|
|
+const QString TrashDir = QStandardPaths::writableLocation(QStandardPaths::HomeLocation) + "/.local/share/Trash";
|
|
const QDir::Filters ItemsShouldCount = QDir::AllEntries | QDir::Hidden | QDir::System | QDir::NoDotAndDotDot;
|
|
|
|
|
|
--
|
|
2.39.3
|
|
|