Gentoo Archives: gentoo-commits

From: Andreas Sturmlechner <asturm@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: kde-frameworks/plasma/files/, kde-frameworks/plasma/
Date: Thu, 20 Jan 2022 13:26:40
Message-Id: 1642685057.a60d9305d2a70497122ceeb0e32dc2c6ac1f9540.asturm@gentoo
1 commit: a60d9305d2a70497122ceeb0e32dc2c6ac1f9540
2 Author: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
3 AuthorDate: Thu Jan 20 11:25:24 2022 +0000
4 Commit: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
5 CommitDate: Thu Jan 20 13:24:17 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a60d9305
7
8 kde-frameworks/plasma: Always sync the setPanelBehavior to wayland
9
10 Upstream commit d40d36057a0ee9fcb4badc7ff8b56844da79dfc8
11 KDE-bug: https://bugs.kde.org/show_bug.cgi?id=426969
12
13 Package-Manager: Portage-3.0.30, Repoman-3.0.3
14 Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>
15
16 .../plasma/files/plasma-5.90.0-KDEBUG-426969.patch | 90 ++++++++++++++++++++++
17 kde-frameworks/plasma/plasma-5.90.0-r1.ebuild | 1 +
18 2 files changed, 91 insertions(+)
19
20 diff --git a/kde-frameworks/plasma/files/plasma-5.90.0-KDEBUG-426969.patch b/kde-frameworks/plasma/files/plasma-5.90.0-KDEBUG-426969.patch
21 new file mode 100644
22 index 000000000000..bccc097a3b99
23 --- /dev/null
24 +++ b/kde-frameworks/plasma/files/plasma-5.90.0-KDEBUG-426969.patch
25 @@ -0,0 +1,90 @@
26 +From d40d36057a0ee9fcb4badc7ff8b56844da79dfc8 Mon Sep 17 00:00:00 2001
27 +From: David Edmundson <kde@×××××××××××××××××.uk>
28 +Date: Wed, 12 Jan 2022 22:21:34 +0000
29 +Subject: [PATCH] Always sync the setPanelBehavior to wayland
30 +
31 +Currently this code is in the else statement to if (type !=
32 +Dialog::Normal) {
33 +
34 +This doesn't make sense as panel roles apply explicitly to other types,
35 +like Dialog::Dock. On X11 the equivalent always applies.
36 +
37 +BUG: 426969
38 +
39 +* asturm 2022-01-22: Merged with below fixup:
40 +
41 +From b882b34d7b55975f679133ef86cfd12869e8bba5 Mon Sep 17 00:00:00 2001
42 +From: David Edmundson <kde@×××××××××××××××××.uk>
43 +Date: Thu, 13 Jan 2022 17:03:38 +0000
44 +Subject: [PATCH] Always sync the setPanelBehavior to wayland
45 +
46 +The previous patch moved some code that reapplied setRole in a way that
47 +caused issues.
48 +
49 +BUG: 448373
50 +
51 +--- a/src/plasmaquick/dialog.cpp
52 ++++ b/src/plasmaquick/dialog.cpp
53 +@@ -693,14 +693,13 @@
54 +
55 + void DialogPrivate::applyType()
56 + {
57 +- if (type != Dialog::Normal) {
58 + /*QXcbWindowFunctions::WmWindowType*/ int wmType = 0;
59 +
60 + #if HAVE_X11
61 + if (KWindowSystem::isPlatformX11()) {
62 + switch (type) {
63 + case Dialog::Normal:
64 +- Q_UNREACHABLE();
65 ++ q->setFlags(Qt::FramelessWindowHint | q->flags());
66 + break;
67 + case Dialog::Dock:
68 + wmType = QXcbWindowFunctions::WmWindowType::Dock;
69 +@@ -729,11 +728,15 @@
70 + }
71 + #endif
72 +
73 +- if (!wmType) {
74 ++ if (!wmType && type != Dialog::Normal) {
75 + KWindowSystem::setType(q->winId(), static_cast<NET::WindowType>(type));
76 + }
77 + #if HAVE_KWAYLAND
78 + if (shellSurface) {
79 ++ if (q->flags() & Qt::WindowStaysOnTopHint) {
80 ++ type = Dialog::Dock;
81 ++ shellSurface->setPanelBehavior(KWayland::Client::PlasmaShellSurface::PanelBehavior::WindowsGoBelow);
82 ++ }
83 + switch (type) {
84 + case Dialog::Dock:
85 + shellSurface->setRole(KWayland::Client::PlasmaShellSurface::Role::Panel);
86 +@@ -750,27 +753,13 @@
87 + case Dialog::CriticalNotification:
88 + shellSurface->setRole(KWayland::Client::PlasmaShellSurface::Role::CriticalNotification);
89 + break;
90 ++ case Dialog::Normal:
91 ++ shellSurface->setRole(KWayland::Client::PlasmaShellSurface::Role::Normal);
92 + default:
93 + break;
94 + }
95 + }
96 + #endif
97 +- } else {
98 +- q->setFlags(Qt::FramelessWindowHint | q->flags());
99 +-
100 +-#if HAVE_KWAYLAND
101 +- // Only possible after setup
102 +- if (shellSurface) {
103 +- if (q->flags() & Qt::WindowStaysOnTopHint) {
104 +- shellSurface->setRole(KWayland::Client::PlasmaShellSurface::Role::Panel);
105 +- shellSurface->setPanelBehavior(KWayland::Client::PlasmaShellSurface::PanelBehavior::WindowsGoBelow);
106 +- } else {
107 +- shellSurface->setRole(KWayland::Client::PlasmaShellSurface::Role::Normal);
108 +- shellSurface->setPanelBehavior(KWayland::Client::PlasmaShellSurface::PanelBehavior::AlwaysVisible);
109 +- }
110 +- }
111 +-#endif
112 +- }
113 +
114 + // an OSD can't be a Dialog, as qt xcb would attempt to set a transient parent for it
115 + // see bug 370433
116
117 diff --git a/kde-frameworks/plasma/plasma-5.90.0-r1.ebuild b/kde-frameworks/plasma/plasma-5.90.0-r1.ebuild
118 index fa06b05e874f..a59a50636a36 100644
119 --- a/kde-frameworks/plasma/plasma-5.90.0-r1.ebuild
120 +++ b/kde-frameworks/plasma/plasma-5.90.0-r1.ebuild
121 @@ -60,6 +60,7 @@ DEPEND="${RDEPEND}
122 BDEPEND="man? ( >=kde-frameworks/kdoctools-${PVCUT}:5 )"
123
124 PATCHES=(
125 + "${FILESDIR}/${P}-KDEBUG-426969.patch"
126 "${FILESDIR}/${P}-KDEBUG-447752.patch"
127 "${FILESDIR}/${P}-KDEBUG-448590.patch"
128 )