temp/gnome-shell-mobile: apply patches here too
Apply the same patches that were just added to extra-repos/systemd/gnome-shell-mobile to temp/gnome-shell-mobile as well. Signed-off-by: Oliver Smith <ollieparanoid@postmarketos.org> Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/8798>
This commit is contained in:
parent
a3a2689d5e
commit
120808693a
3 changed files with 78 additions and 1 deletions
|
|
@ -0,0 +1,36 @@
|
|||
From 8c97d8ab5e92e355c7f6aa6d0271556115c3648f Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?C=C3=A9dric=20Bellegarde?= <cedric.bellegarde@adishatz.org>
|
||||
Date: Fri, 6 Mar 2026 08:36:19 +0100
|
||||
Subject: [PATCH] windowPreview: Only try to close closable windows
|
||||
|
||||
When swiping to close an application, _deleteAll() iterates over all
|
||||
windows associated with the app and calls delete() on each. This
|
||||
crashes if the app has a transient popup window (e.g. a dropdown menu)
|
||||
still open handler, resulting in a null function pointer dereference inside
|
||||
meta_window_delete() (delete.c:119).
|
||||
|
||||
Fix this by guarding the delete() call with can_close(), skipping any
|
||||
window that Mutter has determined cannot be explicitly closed. These
|
||||
windows (popups, dropdown menus) will be destroyed naturally as part of
|
||||
the Wayland surface teardown when their parent toplevel is deleted.
|
||||
---
|
||||
js/ui/windowPreview.js | 3 ++-
|
||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/js/ui/windowPreview.js b/js/ui/windowPreview.js
|
||||
index cd43ceab0..9dae8e1df 100644
|
||||
--- a/js/ui/windowPreview.js
|
||||
+++ b/js/ui/windowPreview.js
|
||||
@@ -478,7 +478,8 @@ export const WindowPreview = GObject.registerClass({
|
||||
|
||||
// Delete all windows, starting from the bottom-most (most-modal) one
|
||||
for (const window of windows.reverse())
|
||||
- window.delete(global.get_current_time());
|
||||
+ if (window.can_close())
|
||||
+ window.delete(global.get_current_time());
|
||||
|
||||
this._closeRequested = true;
|
||||
}
|
||||
--
|
||||
GitLab
|
||||
|
||||
|
|
@ -0,0 +1,37 @@
|
|||
commit 5fd671ad3ccbcd3cd65f0e8ec1e1d1692d31bba7
|
||||
Author: Cédric Bellegarde <cedric.bellegarde@adishatz.org>
|
||||
Date: Thu Jun 11 16:13:12 2026 +0200
|
||||
|
||||
keyboard: Avoid spinning idle source when window actor is unavailable
|
||||
|
||||
FocusTracker defers handling of newly created windows through an
|
||||
idle source and checks whether the corresponding Meta.WindowActor is
|
||||
available.
|
||||
|
||||
The callback currently returns SOURCE_CONTINUE when
|
||||
get_compositor_private() returns null. Since this is an idle source,
|
||||
returning SOURCE_CONTINUE causes it to be re-scheduled on every main
|
||||
loop iteration until the actor becomes available. In practice this can
|
||||
result in a busy loop, with the main loop repeatedly polling without
|
||||
blocking and consuming significant CPU time.
|
||||
|
||||
A Meta.WindowActor is normally available when the window-created signal
|
||||
is emitted, so there is no reason to keep retrying from an idle
|
||||
handler. Treat a missing actor as a terminal condition and remove the
|
||||
source instead.
|
||||
|
||||
Fix #70
|
||||
|
||||
diff --git a/js/ui/keyboard.js b/js/ui/keyboard.js
|
||||
index 8e551b48f..16f28b3f9 100644
|
||||
--- a/js/ui/keyboard.js
|
||||
+++ b/js/ui/keyboard.js
|
||||
@@ -839,7 +839,7 @@ class FocusTracker extends Signals.EventEmitter {
|
||||
GLib.idle_add(GLib.PRIORITY_DEFAULT_IDLE, () => {
|
||||
const windowActor = window.get_compositor_private();
|
||||
if (!windowActor)
|
||||
- return GLib.SOURCE_CONTINUE;
|
||||
+ return GLib.SOURCE_REMOVE;
|
||||
|
||||
// We assume skip_taskbar windows are popovers
|
||||
if (window.skip_taskbar) {
|
||||
|
|
@ -4,7 +4,7 @@
|
|||
maintainer="Stefan Hansson <newbyte@postmarketos.org>"
|
||||
pkgname=gnome-shell-mobile
|
||||
pkgver=48.0
|
||||
pkgrel=7
|
||||
pkgrel=8
|
||||
pkgdesc="GNOME shell"
|
||||
url="https://wiki.gnome.org/Projects/GnomeShell"
|
||||
# armhf: gjs -> mozjs
|
||||
|
|
@ -84,6 +84,8 @@ source="gnome-shell-mobile-$_commit.tar.gz::https://gitlab.gnome.org/verdre/gnom
|
|||
0002-Revert-main-Notify-gnome-session-when-we-re-ready.patch
|
||||
0003-data-Drop-org.gnome.Shell.desktop.patch
|
||||
0004-data-Overhaul-systemd-units.patch
|
||||
0005-windowPreview-Only-try-to-close-closable-windows.patch
|
||||
0006-keyboard-Avoid-spinning-idle-source-when-window-actor-is-unavailable.patch
|
||||
"
|
||||
builddir="$srcdir/gnome-shell-mobile-$_commit"
|
||||
options="!check" # Tests have circular dependency 'gnome-shell <-> gdm'
|
||||
|
|
@ -150,4 +152,6 @@ dec336bf74305fa016ffc1f9272e2b671c41dba458ebbf62b782a3dd091f02ae85315f139ab7ac40
|
|||
f10643bf010135cdc2d6bc122d47d4905e6ef3cea5e7a82e44d9a5d66ec147cd85872eaf869d05c1477ad5211a499d2351b4a20ee0085af1ff933769230bc242 0002-Revert-main-Notify-gnome-session-when-we-re-ready.patch
|
||||
0f859f4c879a432cddf0127f518b95ed4f21720be6490ee96b17414cae461e5dd643d8d918376c2656a08c5537c79b069d3acf6838b5b3ea0b4f880d620ad3e7 0003-data-Drop-org.gnome.Shell.desktop.patch
|
||||
413bd3cd1ba63dae79afc84a2cc1cdce7b8ea8f5457fdae7a1472ea41d0c6c93a8b66c115bd112699b72ea8b7f1050d8cda23f1259f14c7b0fd7b423a1afde35 0004-data-Overhaul-systemd-units.patch
|
||||
19859a78910afe6af7e7c52a616f817051eeef2741361228eb8da41c77f5834b939cbcd4954d6b98c353d61e516fadccc1ff674ac77c854c7745f07ee8974d85 0005-windowPreview-Only-try-to-close-closable-windows.patch
|
||||
df9693e0bd6ca7d8157a69b0849882958d552d28334fe4bea2e6794cc0b65c43b6c318a1b5168963fae7ea7569b78e62fdb59189da7df946f7e1e4564b0328be 0006-keyboard-Avoid-spinning-idle-source-when-window-actor-is-unavailable.patch
|
||||
"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue