Gentoo Archives: gentoo-commits

From: Andreas Sturmlechner <asturm@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] proj/kde:master commit in: kde-plasma/plasma-workspace/files/, kde-plasma/plasma-workspace/
Date: Wed, 05 May 2021 03:00:40
Message-Id: 1620183607.a82cfe37988730033815c61bc4895642d6cc0dfb.asturm@gentoo
1 commit: a82cfe37988730033815c61bc4895642d6cc0dfb
2 Author: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
3 AuthorDate: Wed May 5 02:50:57 2021 +0000
4 Commit: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
5 CommitDate: Wed May 5 03:00:07 2021 +0000
6 URL: https://gitweb.gentoo.org/proj/kde.git/commit/?id=a82cfe37
7
8 kde-plasma/plasma-workspace: Remove dangerous default shortcuts
9
10 Upstream commit e8e17c5ef8734fa56a78405e32277568e4e1095e
11
12 KDE-bug: https://bugs.kde.org/show_bug.cgi?id=435954
13 Package-Manager: Portage-3.0.18, Repoman-3.0.3
14 Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>
15
16 ...asma-workspace-5.21.5-dangerous-shortcuts.patch | 45 ++++++++++++++++++++++
17 .../plasma-workspace-5.21.5.ebuild | 1 +
18 2 files changed, 46 insertions(+)
19
20 diff --git a/kde-plasma/plasma-workspace/files/plasma-workspace-5.21.5-dangerous-shortcuts.patch b/kde-plasma/plasma-workspace/files/plasma-workspace-5.21.5-dangerous-shortcuts.patch
21 new file mode 100644
22 index 0000000000..f04bb866d5
23 --- /dev/null
24 +++ b/kde-plasma/plasma-workspace/files/plasma-workspace-5.21.5-dangerous-shortcuts.patch
25 @@ -0,0 +1,45 @@
26 +From e8e17c5ef8734fa56a78405e32277568e4e1095e Mon Sep 17 00:00:00 2001
27 +From: Nate Graham <nate@×××.org>
28 +Date: Thu, 22 Apr 2021 08:38:18 -0600
29 +Subject: [PATCH] [ksmserver] Remove default shortcuts for "Without
30 + Confirmation" actions
31 +
32 +These actions bypass the user setting for whether or not to show the
33 +logout screen and always log out/reboot/etc. immediately. Because they
34 +have default keyboard shortcuts, they can be triggered by accident and
35 +cause unexpected logouts/reboots/etc.
36 +
37 +BUG: 435954
38 +FIXED-IN: 5.22
39 +---
40 + ksmserver/server.cpp | 6 +++---
41 + 1 file changed, 3 insertions(+), 3 deletions(-)
42 +
43 +diff --git a/ksmserver/server.cpp b/ksmserver/server.cpp
44 +index ac9da9f09..6f3179fb9 100644
45 +--- a/ksmserver/server.cpp
46 ++++ b/ksmserver/server.cpp
47 +@@ -880,17 +880,17 @@ void KSMServer::setupShortcuts()
48 +
49 + a = actionCollection->addAction(QStringLiteral("Log Out Without Confirmation"));
50 + a->setText(i18n("Log Out Without Confirmation"));
51 +- KGlobalAccel::self()->setGlobalShortcut(a, QList<QKeySequence>() << Qt::ALT + Qt::CTRL + Qt::SHIFT + Qt::Key_Delete);
52 ++ KGlobalAccel::self()->setGlobalShortcut(a, QKeySequence());
53 + connect(a, &QAction::triggered, this, &KSMServer::logoutWithoutConfirmation);
54 +
55 + a = actionCollection->addAction(QStringLiteral("Halt Without Confirmation"));
56 + a->setText(i18n("Halt Without Confirmation"));
57 +- KGlobalAccel::self()->setGlobalShortcut(a, QList<QKeySequence>() << Qt::ALT + Qt::CTRL + Qt::SHIFT + Qt::Key_PageDown);
58 ++ KGlobalAccel::self()->setGlobalShortcut(a, QKeySequence());
59 + connect(a, &QAction::triggered, this, &KSMServer::haltWithoutConfirmation);
60 +
61 + a = actionCollection->addAction(QStringLiteral("Reboot Without Confirmation"));
62 + a->setText(i18n("Reboot Without Confirmation"));
63 +- KGlobalAccel::self()->setGlobalShortcut(a, QList<QKeySequence>() << Qt::ALT + Qt::CTRL + Qt::SHIFT + Qt::Key_PageUp);
64 ++ KGlobalAccel::self()->setGlobalShortcut(a, QKeySequence());
65 + connect(a, &QAction::triggered, this, &KSMServer::rebootWithoutConfirmation);
66 + }
67 + }
68 +--
69 +GitLab
70 +
71
72 diff --git a/kde-plasma/plasma-workspace/plasma-workspace-5.21.5.ebuild b/kde-plasma/plasma-workspace/plasma-workspace-5.21.5.ebuild
73 index 31b3b92188..b8e5237f6d 100644
74 --- a/kde-plasma/plasma-workspace/plasma-workspace-5.21.5.ebuild
75 +++ b/kde-plasma/plasma-workspace/plasma-workspace-5.21.5.ebuild
76 @@ -147,6 +147,7 @@ PATCHES=(
77 "${FILESDIR}/${PN}-5.14.2-split-libkworkspace.patch"
78 "${FILESDIR}/${P}-transparency.patch" # KDE-bug 434202
79 "${FILESDIR}/${P}-transparency-panelConfig.patch" # KDE-bug 434285
80 + "${FILESDIR}/${P}-dangerous-shortcuts.patch" # KDE-bug 435954
81 )
82
83 src_prepare() {