commit:     deda9bbdb1d52f9f030ce978a214430c86695d3e
Author:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Tue Sep 29 12:31:28 2020 +0000
Commit:     Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Tue Sep 29 12:46:44 2020 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=deda9bbd

kde-plasma/plasma-integration: Make folder view don't move to trash on Ctrl+D

Upstream commit 15c7926377065da0fea111be303816dca91d087a

KDE-Bug: https://bugs.kde.org/show_bug.cgi?id=426573
Package-Manager: Portage-3.0.8, Repoman-3.0.1
Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>

 ...e-standard-kde-shortcut-for-move-to-trash.patch | 34 +++++++++++++++
 .../plasma-integration-5.19.5-r1.ebuild            | 50 ++++++++++++++++++++++
 2 files changed, 84 insertions(+)

diff --git 
a/kde-plasma/plasma-integration/files/plasma-integration-5.19.5-use-standard-kde-shortcut-for-move-to-trash.patch
 
b/kde-plasma/plasma-integration/files/plasma-integration-5.19.5-use-standard-kde-shortcut-for-move-to-trash.patch
new file mode 100644
index 00000000000..7405dace6be
--- /dev/null
+++ 
b/kde-plasma/plasma-integration/files/plasma-integration-5.19.5-use-standard-kde-shortcut-for-move-to-trash.patch
@@ -0,0 +1,34 @@
+From 15c7926377065da0fea111be303816dca91d087a Mon Sep 17 00:00:00 2001
+From: Nate Graham <[email protected]>
+Date: Tue, 15 Sep 2020 13:31:48 -0600
+Subject: [PATCH] Use KDE shortcuts for "move to trash" action coming from
+ QStandardKey
+
+QKeySequence::Delete is the Qt "Move to trash" action, which, by
+default, includes Ctrl+D as a shortcut. This is something we don't want
+in KDE software, so we need to intercept this action in our integration
+plugin and give it the standard KDE shortcuts instead, as we do for
+other actions.
+
+BUG: 426573
+FIXED-IN: 5.20
+---
+ src/platformtheme/kdeplatformtheme.cpp | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/src/platformtheme/kdeplatformtheme.cpp 
b/src/platformtheme/kdeplatformtheme.cpp
+index 24ac7e7..18b3f6f 100644
+--- a/src/platformtheme/kdeplatformtheme.cpp
++++ b/src/platformtheme/kdeplatformtheme.cpp
+@@ -257,6 +257,8 @@ QList<QKeySequence> 
KdePlatformTheme::keyBindings(QKeySequence::StandardKey key)
+         return KStandardShortcut::shortcut(KStandardShortcut::TabNext);
+     case QKeySequence::PreviousChild:
+         return KStandardShortcut::shortcut(KStandardShortcut::TabPrev);
++    case QKeySequence::Delete:
++        return KStandardShortcut::shortcut(KStandardShortcut::MoveToTrash);
+     default:
+         return QPlatformTheme::keyBindings(key);
+     }
+-- 
+GitLab
+

diff --git a/kde-plasma/plasma-integration/plasma-integration-5.19.5-r1.ebuild 
b/kde-plasma/plasma-integration/plasma-integration-5.19.5-r1.ebuild
new file mode 100644
index 00000000000..51a301c73ca
--- /dev/null
+++ b/kde-plasma/plasma-integration/plasma-integration-5.19.5-r1.ebuild
@@ -0,0 +1,50 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+KFMIN=5.71.0
+PVCUT=$(ver_cut 1-3)
+QTMIN=5.14.2
+VIRTUALX_REQUIRED="test"
+inherit ecm kde.org
+
+DESCRIPTION="Qt Platform Theme integration plugins for the Plasma workspaces"
+
+LICENSE="LGPL-2+"
+SLOT="5"
+KEYWORDS="~amd64 ~arm ~arm64 ~ppc64 ~x86"
+IUSE=""
+
+DEPEND="
+       >=dev-qt/qtdbus-${QTMIN}:5
+       >=dev-qt/qtgui-${QTMIN}:5=[dbus]
+       >=dev-qt/qtquickcontrols2-${QTMIN}:5
+       >=dev-qt/qtwidgets-${QTMIN}:5
+       >=dev-qt/qtx11extras-${QTMIN}:5
+       >=kde-frameworks/kcompletion-${KFMIN}:5
+       >=kde-frameworks/kconfig-${KFMIN}:5
+       >=kde-frameworks/kconfigwidgets-${KFMIN}:5
+       >=kde-frameworks/kcoreaddons-${KFMIN}:5
+       >=kde-frameworks/ki18n-${KFMIN}:5
+       >=kde-frameworks/kiconthemes-${KFMIN}:5
+       >=kde-frameworks/kio-${KFMIN}:5
+       >=kde-frameworks/kjobwidgets-${KFMIN}:5
+       >=kde-frameworks/knotifications-${KFMIN}:5
+       >=kde-frameworks/kwayland-${KFMIN}:5
+       >=kde-frameworks/kwidgetsaddons-${KFMIN}:5
+       >=kde-frameworks/kwindowsystem-${KFMIN}:5
+       >=kde-frameworks/kxmlgui-${KFMIN}:5
+       >=kde-plasma/breeze-${PVCUT}:5
+       x11-libs/libXcursor
+       x11-libs/libxcb
+"
+RDEPEND="${DEPEND}
+       media-fonts/hack
+       media-fonts/noto
+"
+
+# requires running kde environment
+RESTRICT+=" test"
+
+PATCHES=( "${FILESDIR}"/${P}-use-standard-kde-shortcut-for-move-to-trash.patch 
)

Reply via email to