Import CS
This commit is contained in:
parent
f861c0441f
commit
55e4312ca7
2
.gitignore
vendored
2
.gitignore
vendored
@ -1 +1 @@
|
||||
gnome-shell-47.4.tar.xz
|
||||
gnome-shell-49.4.tar.xz
|
||||
|
||||
@ -0,0 +1,27 @@
|
||||
From 67bb91b741b5a30624c02cbc65c9f2a1bfe4ac6f Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 27 Aug 2025 13:25:01 +0200
|
||||
Subject: [PATCH] Revert "Require gjs >= 1.81.2 for build because
|
||||
Intl.Segmenter is needed"
|
||||
|
||||
This reverts commit 9ce0cf036e4b22b6933e5425a0604fd0135d8b31.
|
||||
---
|
||||
meson.build | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/meson.build b/meson.build
|
||||
index 327e5f0b7e..f1df40f702 100644
|
||||
--- a/meson.build
|
||||
+++ b/meson.build
|
||||
@@ -23,7 +23,7 @@ eds_req = '>= 3.33.1'
|
||||
gcr_req = '>= 3.90.0'
|
||||
gio_req = '>= 2.79.2'
|
||||
gi_req = '>= 1.49.1'
|
||||
-gjs_req = '>= 1.81.2'
|
||||
+gjs_req = '>= 1.73.1'
|
||||
gtk_req = '>= 4.0'
|
||||
mutter_req = '>= 49.0'
|
||||
polkit_req = '>= 0.100'
|
||||
--
|
||||
2.51.1
|
||||
|
||||
79
0001-Revert-data-Drop-org.gnome.Shell.desktop.patch
Normal file
79
0001-Revert-data-Drop-org.gnome.Shell.desktop.patch
Normal file
@ -0,0 +1,79 @@
|
||||
From 622ee57d6b53011d11e7e22f741766af6424d398 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Thu, 13 Nov 2025 12:57:55 +0100
|
||||
Subject: [PATCH 1/2] Revert "data: Drop org.gnome.Shell.desktop"
|
||||
|
||||
This reverts commit f3911151da7b0e3c630011cb26bd85f719e531d2.
|
||||
---
|
||||
data/meson.build | 13 ++++++++++++-
|
||||
....in => org.gnome.Shell.Extensions.desktop.in.in} | 0
|
||||
...n => org.gnome.Shell.PortalHelper.desktop.in.in} | 0
|
||||
data/org.gnome.Shell.desktop.in.in | 13 +++++++++++++
|
||||
4 files changed, 25 insertions(+), 1 deletion(-)
|
||||
rename data/{org.gnome.Shell.Extensions.desktop.in => org.gnome.Shell.Extensions.desktop.in.in} (100%)
|
||||
rename data/{org.gnome.Shell.PortalHelper.desktop.in => org.gnome.Shell.PortalHelper.desktop.in.in} (100%)
|
||||
create mode 100644 data/org.gnome.Shell.desktop.in.in
|
||||
|
||||
diff --git a/data/meson.build b/data/meson.build
|
||||
index cc7b5e2a1f..76a32ca59f 100644
|
||||
--- a/data/meson.build
|
||||
+++ b/data/meson.build
|
||||
@@ -1,6 +1,7 @@
|
||||
data_builddir = meson.current_build_dir()
|
||||
|
||||
desktop_files = [
|
||||
+ 'org.gnome.Shell.desktop',
|
||||
'org.gnome.Shell.Extensions.desktop',
|
||||
]
|
||||
service_files = []
|
||||
@@ -10,9 +11,19 @@ if have_portal_helper
|
||||
service_files += 'org.gnome.Shell.PortalHelper.service'
|
||||
endif
|
||||
|
||||
+desktopconf = configuration_data()
|
||||
+# We substitute in bindir so it works as an autostart
|
||||
+# file when built in a non-system prefix
|
||||
+desktopconf.set('bindir', bindir)
|
||||
+desktopconf.set('systemd_hidden', have_systemd ? 'true' : 'false')
|
||||
+
|
||||
foreach desktop_file : desktop_files
|
||||
i18n.merge_file(
|
||||
- input: desktop_file + '.in',
|
||||
+ input: configure_file(
|
||||
+ input: desktop_file + '.in.in',
|
||||
+ output: desktop_file + '.in',
|
||||
+ configuration: desktopconf
|
||||
+ ),
|
||||
output: desktop_file,
|
||||
po_dir: po_dir,
|
||||
install: true,
|
||||
diff --git a/data/org.gnome.Shell.Extensions.desktop.in b/data/org.gnome.Shell.Extensions.desktop.in.in
|
||||
similarity index 100%
|
||||
rename from data/org.gnome.Shell.Extensions.desktop.in
|
||||
rename to data/org.gnome.Shell.Extensions.desktop.in.in
|
||||
diff --git a/data/org.gnome.Shell.PortalHelper.desktop.in b/data/org.gnome.Shell.PortalHelper.desktop.in.in
|
||||
similarity index 100%
|
||||
rename from data/org.gnome.Shell.PortalHelper.desktop.in
|
||||
rename to data/org.gnome.Shell.PortalHelper.desktop.in.in
|
||||
diff --git a/data/org.gnome.Shell.desktop.in.in b/data/org.gnome.Shell.desktop.in.in
|
||||
new file mode 100644
|
||||
index 0000000000..59d1cd2fe9
|
||||
--- /dev/null
|
||||
+++ b/data/org.gnome.Shell.desktop.in.in
|
||||
@@ -0,0 +1,13 @@
|
||||
+[Desktop Entry]
|
||||
+Type=Application
|
||||
+Name=GNOME Shell
|
||||
+Comment=Window management and application launching
|
||||
+Exec=@bindir@/gnome-shell
|
||||
+Categories=GNOME;GTK;Core;
|
||||
+OnlyShowIn=GNOME;
|
||||
+NoDisplay=true
|
||||
+X-GNOME-Autostart-Phase=DisplayServer
|
||||
+X-GNOME-Provides=panel;windowmanager;
|
||||
+X-GNOME-Autostart-Notify=true
|
||||
+X-GNOME-AutoRestart=false
|
||||
+X-GNOME-HiddenUnderSystemd=@systemd_hidden@
|
||||
--
|
||||
2.51.1
|
||||
|
||||
@ -0,0 +1,45 @@
|
||||
From df7e3d8e4e4f5d6d875d1c1a48d23475dc98dc80 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Fri, 7 Nov 2025 19:57:25 +0100
|
||||
Subject: [PATCH] Revert "status/keyboard: Limit the input method indicator to
|
||||
< 3 grapheme clusters"
|
||||
|
||||
The change requires support for Intl.Segmenter that was introduced
|
||||
in mozjs-125. RHEL still includes an older gjs release based on
|
||||
mozjs-115, so revert the change.
|
||||
|
||||
This reverts commit f2246442a0ade263a1f9e775f02818bbd2862ae8.
|
||||
---
|
||||
js/ui/status/keyboard.js | 9 +--------
|
||||
1 file changed, 1 insertion(+), 8 deletions(-)
|
||||
|
||||
diff --git a/js/ui/status/keyboard.js b/js/ui/status/keyboard.js
|
||||
index 62f1e731db..7f00e289e3 100644
|
||||
--- a/js/ui/status/keyboard.js
|
||||
+++ b/js/ui/status/keyboard.js
|
||||
@@ -1005,12 +1005,6 @@ class InputSourceIndicator extends PanelMenu.Button {
|
||||
}
|
||||
}
|
||||
|
||||
- _getGraphemeClusters(text = '') {
|
||||
- const segmenter = new Intl.Segmenter(undefined, {granularity: 'grapheme'});
|
||||
- const segments = [...segmenter.segment(text)].map(o => o.segment);
|
||||
- return segments;
|
||||
- }
|
||||
-
|
||||
_buildPropSubMenu(menu, props) {
|
||||
if (!props)
|
||||
return;
|
||||
@@ -1034,8 +1028,7 @@ class InputSourceIndicator extends PanelMenu.Button {
|
||||
let currentSource = this._inputSourceManager.currentSource;
|
||||
if (currentSource) {
|
||||
let indicatorLabel = this._indicatorLabels[currentSource.index];
|
||||
- const graphemeClusters = this._getGraphemeClusters(text);
|
||||
- if (graphemeClusters.length > 0 && graphemeClusters.length < 3)
|
||||
+ if (text && text.length > 0 && text.length < 3)
|
||||
indicatorLabel.set_text(text);
|
||||
}
|
||||
}
|
||||
--
|
||||
2.51.1
|
||||
|
||||
9185
0001-Support-for-web-login-and-unified-auth-mechanism.patch
Normal file
9185
0001-Support-for-web-login-and-unified-auth-mechanism.patch
Normal file
File diff suppressed because it is too large
Load Diff
@ -1,4 +1,4 @@
|
||||
From 55c1dfed04084e9dbaf034263172bc745f905718 Mon Sep 17 00:00:00 2001
|
||||
From 9529c76492722852802aa7aa8d351e98610487ff Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 20 May 2015 16:44:00 +0200
|
||||
Subject: [PATCH] app: Fall back to window title instead of WM_CLASS
|
||||
@ -11,10 +11,10 @@ a .desktop file ...
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/src/shell-app.c b/src/shell-app.c
|
||||
index 04d0ab508b..4a55daf809 100644
|
||||
index 916783a597..9a90daa1dc 100644
|
||||
--- a/src/shell-app.c
|
||||
+++ b/src/shell-app.c
|
||||
@@ -247,7 +247,7 @@ shell_app_get_name (ShellApp *app)
|
||||
@@ -262,7 +262,7 @@ shell_app_get_name (ShellApp *app)
|
||||
const char *name = NULL;
|
||||
|
||||
if (window)
|
||||
@ -24,5 +24,5 @@ index 04d0ab508b..4a55daf809 100644
|
||||
name = C_("program", "Unknown");
|
||||
return name;
|
||||
--
|
||||
2.45.2
|
||||
2.51.1
|
||||
|
||||
|
||||
27
0001-build-Lower-gsettings-desktop-schemas-requirement.patch
Normal file
27
0001-build-Lower-gsettings-desktop-schemas-requirement.patch
Normal file
@ -0,0 +1,27 @@
|
||||
From 196fce5906753d6dad766dac4494038ff89599c8 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Mon, 10 Nov 2025 12:43:12 +0100
|
||||
Subject: [PATCH] build: Lower gsettings-desktop-schemas requirement
|
||||
|
||||
The module won't be rebased to 49.x, instead the required schema
|
||||
additions have been backported.
|
||||
---
|
||||
meson.build | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/meson.build b/meson.build
|
||||
index f1df40f702..decb2ba136 100644
|
||||
--- a/meson.build
|
||||
+++ b/meson.build
|
||||
@@ -27,7 +27,7 @@ gjs_req = '>= 1.73.1'
|
||||
gtk_req = '>= 4.0'
|
||||
mutter_req = '>= 49.0'
|
||||
polkit_req = '>= 0.100'
|
||||
-schemas_req = '>= 49.alpha'
|
||||
+schemas_req = '>= 47.0'
|
||||
systemd_req = '>= 246'
|
||||
gnome_desktop_req = '>= 40'
|
||||
pipewire_req = '>= 0.3.49'
|
||||
--
|
||||
2.51.1
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@ -1,4 +1,4 @@
|
||||
From 7e82f0a73a1d1576e94b17e21d07fd3978ba7c33 Mon Sep 17 00:00:00 2001
|
||||
From aab759b25529480698b745393067d60b48b04e3d Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Mon, 1 Feb 2021 18:26:00 +0100
|
||||
Subject: [PATCH] extensionDownloader: Refuse to override system extensions
|
||||
@ -13,10 +13,10 @@ already installed system-wide.
|
||||
1 file changed, 9 insertions(+)
|
||||
|
||||
diff --git a/js/ui/extensionDownloader.js b/js/ui/extensionDownloader.js
|
||||
index 0366c5dfa8..5b27543aa6 100644
|
||||
index fe687cba43..cc6cd0a0b5 100644
|
||||
--- a/js/ui/extensionDownloader.js
|
||||
+++ b/js/ui/extensionDownloader.js
|
||||
@@ -39,6 +39,15 @@ export async function installExtension(uuid, invocation) {
|
||||
@@ -37,6 +37,15 @@ export async function installExtension(uuid, invocation) {
|
||||
return;
|
||||
}
|
||||
|
||||
@ -33,5 +33,5 @@ index 0366c5dfa8..5b27543aa6 100644
|
||||
uuid,
|
||||
shell_version: Config.PACKAGE_VERSION,
|
||||
--
|
||||
2.45.2
|
||||
2.51.1
|
||||
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
From ff73f820b1398e5d60b8984b0003db46ad70b8ec Mon Sep 17 00:00:00 2001
|
||||
From 5293ee585f876169e31f3b6af737a42d30302f71 Mon Sep 17 00:00:00 2001
|
||||
From: Benjamin Berg <bberg@redhat.com>
|
||||
Date: Wed, 28 Apr 2021 16:50:03 +0200
|
||||
Subject: [PATCH] gdm: Work around failing fingerprint auth
|
||||
@ -9,44 +9,70 @@ the PAM configuration has not been updated and no prints are enrolled.
|
||||
So, consider a verification failure within one second to be a service
|
||||
failure instead.
|
||||
---
|
||||
js/gdm/util.js | 18 ++++++++++++++++++
|
||||
1 file changed, 18 insertions(+)
|
||||
js/gdm/authServicesLegacy.js | 44 +++++++++++++++++++++++++-----------
|
||||
1 file changed, 31 insertions(+), 13 deletions(-)
|
||||
|
||||
diff --git a/js/gdm/util.js b/js/gdm/util.js
|
||||
index 97df6d687e..371953cb25 100644
|
||||
--- a/js/gdm/util.js
|
||||
+++ b/js/gdm/util.js
|
||||
@@ -109,6 +109,7 @@ export class ShellUserVerifier extends Signals.EventEmitter {
|
||||
this._defaultService = null;
|
||||
this._preemptingService = null;
|
||||
this._fingerprintReaderType = FingerprintReaderType.NONE;
|
||||
+ this._fprintStartTime = -1;
|
||||
diff --git a/js/gdm/authServicesLegacy.js b/js/gdm/authServicesLegacy.js
|
||||
index 0813622a01..c85a9572f5 100644
|
||||
--- a/js/gdm/authServicesLegacy.js
|
||||
+++ b/js/gdm/authServicesLegacy.js
|
||||
@@ -58,6 +58,7 @@ export class AuthServicesLegacy extends AuthServices {
|
||||
this._addCredentialManager(Vmware.SERVICE_NAME, Vmware.getVmwareCredentialsManager());
|
||||
|
||||
this._messageQueue = [];
|
||||
this._messageQueueTimeoutId = 0;
|
||||
@@ -669,6 +670,10 @@ export class ShellUserVerifier extends Signals.EventEmitter {
|
||||
this._hold.acquire();
|
||||
try {
|
||||
this._activeServices.add(serviceName);
|
||||
this._fingerprintReadyTimeoutId = 0;
|
||||
+ this._fprintStartTime = -1;
|
||||
}
|
||||
|
||||
_handleSelectChoice(serviceName, key) {
|
||||
@@ -117,16 +118,20 @@ export class AuthServicesLegacy extends AuthServices {
|
||||
}
|
||||
|
||||
_handleOnConversationStarted(serviceName) {
|
||||
- if (serviceName === Const.FINGERPRINT_SERVICE_NAME &&
|
||||
- this._fingerprintReadyTimeoutId === 0) {
|
||||
- this._fingerprintReadyTimeoutId = GLib.timeout_add(
|
||||
- GLib.PRIORITY_DEFAULT,
|
||||
- FINGERPRINT_READY_TIMEOUT_MS,
|
||||
- () => {
|
||||
- this._fingerprintReadyTimeoutId = 0;
|
||||
- this._setFingerprintReady();
|
||||
- return GLib.SOURCE_REMOVE;
|
||||
- });
|
||||
+ if (serviceName === Const.FINGERPRINT_SERVICE_NAME) {
|
||||
+ this._fprintStartTime = GLib.get_monotonic_time();
|
||||
+
|
||||
+ if (serviceName == FINGERPRINT_SERVICE_NAME)
|
||||
+ this._fprintStartTime = GLib.get_monotonic_time();
|
||||
+
|
||||
if (this._userName) {
|
||||
await this._userVerifier.call_begin_verification_for_user(
|
||||
serviceName, this._userName, this._cancellable);
|
||||
@@ -763,6 +768,7 @@ export class ShellUserVerifier extends Signals.EventEmitter {
|
||||
const cancellable = this._cancellable;
|
||||
this._fingerprintFailedId = GLib.timeout_add(GLib.PRIORITY_DEFAULT,
|
||||
FINGERPRINT_ERROR_TIMEOUT_WAIT, () => {
|
||||
+ log("Generating _verificationFailed!");
|
||||
this._fingerprintFailedId = 0;
|
||||
if (!cancellable.is_cancelled())
|
||||
this._verificationFailed(serviceName, false);
|
||||
@@ -829,6 +835,18 @@ export class ShellUserVerifier extends Signals.EventEmitter {
|
||||
if (serviceName === FINGERPRINT_SERVICE_NAME) {
|
||||
if (this._fingerprintFailedId)
|
||||
GLib.source_remove(this._fingerprintFailedId);
|
||||
+ if (this._fingerprintReadyTimeoutId === 0) {
|
||||
+ this._fingerprintReadyTimeoutId = GLib.timeout_add(
|
||||
+ GLib.PRIORITY_DEFAULT,
|
||||
+ FINGERPRINT_READY_TIMEOUT_MS,
|
||||
+ () => {
|
||||
+ this._fingerprintReadyTimeoutId = 0;
|
||||
+ this._setFingerprintReady();
|
||||
+ return GLib.SOURCE_REMOVE;
|
||||
+ });
|
||||
+ }
|
||||
}
|
||||
}
|
||||
|
||||
@@ -234,6 +239,7 @@ export class AuthServicesLegacy extends AuthServices {
|
||||
|
||||
this._fingerprintFailedId = GLib.timeout_add(GLib.PRIORITY_DEFAULT,
|
||||
FINGERPRINT_ERROR_TIMEOUT_WAIT, () => {
|
||||
+ log("Generating _verificationFailed!");
|
||||
this._fingerprintFailedId = 0;
|
||||
if (!this._cancellable.is_cancelled())
|
||||
this._verificationFailed(serviceName, false);
|
||||
@@ -314,9 +320,21 @@ export class AuthServicesLegacy extends AuthServices {
|
||||
|
||||
_handleVerificationFailed(serviceName) {
|
||||
if (serviceName === Const.FINGERPRINT_SERVICE_NAME &&
|
||||
- this._enabledMechanisms.some(m => m.serviceName === serviceName) &&
|
||||
- this._fingerprintFailedId)
|
||||
- GLib.source_remove(this._fingerprintFailedId);
|
||||
+ this._enabledMechanisms.some(m => m.serviceName === serviceName)) {
|
||||
+ if (this._fingerprintFailedId)
|
||||
+ GLib.source_remove(this._fingerprintFailedId);
|
||||
+
|
||||
+ // On Fedora we have the problem that fingerprint auth fails
|
||||
+ // immediately if the PAM configuration has not been updated and no
|
||||
@ -56,12 +82,12 @@ index 97df6d687e..371953cb25 100644
|
||||
+ if (this._fprintStartTime > GLib.get_monotonic_time() - GLib.USEC_PER_SEC) {
|
||||
+ log("Fingerprint service failed almost immediately, considering it unavailable.");
|
||||
+ log("Please fix your configuration by running: authselect select --force sssd with-fingerprint with-silent-lastlog");
|
||||
+ this._onServiceUnavailable(this._client, serviceName, null);
|
||||
+ return;
|
||||
+ this._onServiceUnavailable(serviceName, null);
|
||||
+ }
|
||||
}
|
||||
+ }
|
||||
}
|
||||
|
||||
// For Not Listed / enterprise logins, immediately reset
|
||||
_handleOnVerificationComplete(serviceName) {
|
||||
--
|
||||
2.43.2
|
||||
2.53.0
|
||||
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
From 2060b040f91c3751861a1c1b985c5fe8cc891d58 Mon Sep 17 00:00:00 2001
|
||||
From e50bb4482d8171b3cad748706b930684e0edccae Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Thu, 29 Oct 2020 18:21:06 +0100
|
||||
Subject: [PATCH] main: Dump stack on segfaults by default
|
||||
@ -8,10 +8,10 @@ Subject: [PATCH] main: Dump stack on segfaults by default
|
||||
1 file changed, 6 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/src/main.c b/src/main.c
|
||||
index 4be47258eb..b324b6b96a 100644
|
||||
index af4fa8597e..03772ec7fb 100644
|
||||
--- a/src/main.c
|
||||
+++ b/src/main.c
|
||||
@@ -47,6 +47,7 @@ static char *script_path = NULL;
|
||||
@@ -46,6 +46,7 @@ static char *script_path = NULL;
|
||||
#define DBUS_REQUEST_NAME_REPLY_PRIMARY_OWNER 1
|
||||
#define DBUS_REQUEST_NAME_REPLY_ALREADY_OWNER 4
|
||||
|
||||
@ -19,7 +19,7 @@ index 4be47258eb..b324b6b96a 100644
|
||||
enum {
|
||||
SHELL_DEBUG_BACKTRACE_WARNINGS = 1,
|
||||
SHELL_DEBUG_BACKTRACE_SEGFAULTS = 2,
|
||||
@@ -381,8 +382,11 @@ shell_init_debug (const char *debug_env)
|
||||
@@ -364,8 +365,11 @@ shell_init_debug (const char *debug_env)
|
||||
{ "backtrace-segfaults", SHELL_DEBUG_BACKTRACE_SEGFAULTS },
|
||||
};
|
||||
|
||||
@ -34,5 +34,5 @@ index 4be47258eb..b324b6b96a 100644
|
||||
|
||||
static GLogWriterOutput
|
||||
--
|
||||
2.45.2
|
||||
2.51.1
|
||||
|
||||
|
||||
46
0001-main-Register-session-with-GDM-on-startup.patch
Normal file
46
0001-main-Register-session-with-GDM-on-startup.patch
Normal file
@ -0,0 +1,46 @@
|
||||
From 32a013304f8c507cb72a5419c7f4b7c553253520 Mon Sep 17 00:00:00 2001
|
||||
From: Adrian Vovk <adrianvovk@gmail.com>
|
||||
Date: Thu, 1 May 2025 18:34:52 -0400
|
||||
Subject: [PATCH] main: Register session with GDM on startup
|
||||
|
||||
When no monitor is connected, gnome-shell starts but never emits
|
||||
`startup-prepared` nor `startup-complete`. As a result, GDM never
|
||||
detects that the shell has launched and plymouthd remains running,
|
||||
preventing the system from reaching graphical.target.
|
||||
|
||||
Ensure that registerSessionWithGDM() is called even when no monitor
|
||||
is connected, so GDM can terminate plymouthd and allow the system to
|
||||
reach graphical.target properly.
|
||||
|
||||
Part of https://gitlab.gnome.org/GNOME/gdm/-/merge_requests/285
|
||||
|
||||
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3708>
|
||||
---
|
||||
js/ui/main.js | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/js/ui/main.js b/js/ui/main.js
|
||||
index ae7a805..1679b3f 100644
|
||||
--- a/js/ui/main.js
|
||||
+++ b/js/ui/main.js
|
||||
@@ -336,6 +336,8 @@ async function _initializeUI() {
|
||||
extensionManager = new ExtensionSystem.ExtensionManager();
|
||||
extensionManager.init();
|
||||
|
||||
+ LoginManager.registerSessionWithGDM();
|
||||
+
|
||||
if (sessionMode.isGreeter && screenShield) {
|
||||
layoutManager.connect('startup-prepared', () => {
|
||||
screenShield.showDialog();
|
||||
@@ -382,8 +384,6 @@ async function _initializeUI() {
|
||||
sessionMode.currentMode !== 'initial-setup')
|
||||
_handleLockScreenWarning();
|
||||
|
||||
- LoginManager.registerSessionWithGDM();
|
||||
-
|
||||
if (perfModule) {
|
||||
let perfOutput = GLib.getenv('SHELL_PERF_OUTPUT');
|
||||
Scripting.runPerfScript(perfModule, perfOutput);
|
||||
--
|
||||
2.51.0
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
From c0b2f60108e7b8cffa10306ef54c620fe71a6735 Mon Sep 17 00:00:00 2001
|
||||
From 755bd786c49c0b37c06aac781d2a7ec34357b49a Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 22 May 2024 18:42:06 +0200
|
||||
Subject: [PATCH] panel: Use branding in activities button
|
||||
@ -10,10 +10,10 @@ Replace the upstream workspace dots with a red hat.
|
||||
2 files changed, 14 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/data/theme/gnome-shell-sass/widgets/_panel.scss b/data/theme/gnome-shell-sass/widgets/_panel.scss
|
||||
index 2a29eee9da..02f8232de6 100644
|
||||
index 1b84dc201f..1514d3ead2 100644
|
||||
--- a/data/theme/gnome-shell-sass/widgets/_panel.scss
|
||||
+++ b/data/theme/gnome-shell-sass/widgets/_panel.scss
|
||||
@@ -58,6 +58,11 @@ $panel_transition_duration: 250ms; // same as the overview transition duration
|
||||
@@ -56,6 +56,11 @@ $panel_transition_duration: 250ms; // same as the overview transition duration
|
||||
min-height: $scalable_icon_size * 0.5;
|
||||
background-color: $panel_fg_color;
|
||||
}
|
||||
@ -26,10 +26,10 @@ index 2a29eee9da..02f8232de6 100644
|
||||
|
||||
// screen activity indicators
|
||||
diff --git a/js/ui/panel.js b/js/ui/panel.js
|
||||
index 62c8ebb31a..1d11cc1b5f 100644
|
||||
index bdb6f7b197..5be0c477c6 100644
|
||||
--- a/js/ui/panel.js
|
||||
+++ b/js/ui/panel.js
|
||||
@@ -425,7 +425,15 @@ class ActivitiesButton extends PanelMenu.Button {
|
||||
@@ -208,7 +208,15 @@ class ActivitiesButton extends PanelMenu.Button {
|
||||
accessible_name: _('Activities'),
|
||||
});
|
||||
|
||||
@ -47,5 +47,5 @@ index 62c8ebb31a..1d11cc1b5f 100644
|
||||
Main.overview.connectObject('showing',
|
||||
() => this.add_style_pseudo_class('checked'),
|
||||
--
|
||||
2.45.2
|
||||
2.51.1
|
||||
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
From 17e77f1729b8542c46d5020d55edce4daf7ab24a Mon Sep 17 00:00:00 2001
|
||||
From 688687465d7f45da81847554221fb8c72d079510 Mon Sep 17 00:00:00 2001
|
||||
From: Ray Strode <rstrode@redhat.com>
|
||||
Date: Fri, 3 Jul 2015 13:54:36 -0400
|
||||
Subject: [PATCH] screenShield: unblank when inserting smartcard
|
||||
@ -13,10 +13,10 @@ action to get the screen to unblank.
|
||||
1 file changed, 3 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/js/ui/screenShield.js b/js/ui/screenShield.js
|
||||
index d2236fb900..b62440dff6 100644
|
||||
index 2087c393ed..428421b370 100644
|
||||
--- a/js/ui/screenShield.js
|
||||
+++ b/js/ui/screenShield.js
|
||||
@@ -94,8 +94,10 @@ export class ScreenShield extends Signals.EventEmitter {
|
||||
@@ -92,8 +92,10 @@ export class ScreenShield extends Signals.EventEmitter {
|
||||
this._smartcardManager = SmartcardManager.getSmartcardManager();
|
||||
this._smartcardManager.connect('smartcard-inserted',
|
||||
(manager, token) => {
|
||||
@ -29,5 +29,5 @@ index d2236fb900..b62440dff6 100644
|
||||
|
||||
this._credentialManagers = {};
|
||||
--
|
||||
2.45.2
|
||||
2.51.1
|
||||
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
From 0bd4ecbbcc47a8574edae46b56695572a846a1e2 Mon Sep 17 00:00:00 2001
|
||||
From b434e61f95b1bb63b8f5e027a718091482be232a Mon Sep 17 00:00:00 2001
|
||||
From: Ray Strode <rstrode@redhat.com>
|
||||
Date: Tue, 15 Jan 2019 12:54:32 -0500
|
||||
Subject: [PATCH] st-texture-cache: purge on resume
|
||||
@ -12,10 +12,10 @@ so the texture cache needs to evict all textures in that situation.
|
||||
3 files changed, 16 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/js/ui/main.js b/js/ui/main.js
|
||||
index 73980edb88..5c17258177 100644
|
||||
index 40898e15c2..bb6d8f6723 100644
|
||||
--- a/js/ui/main.js
|
||||
+++ b/js/ui/main.js
|
||||
@@ -263,7 +263,11 @@ async function _initializeUI() {
|
||||
@@ -298,7 +298,11 @@ async function _initializeUI() {
|
||||
return true;
|
||||
});
|
||||
|
||||
@ -29,7 +29,7 @@ index 73980edb88..5c17258177 100644
|
||||
global.context.connect('notify::unsafe-mode', () => {
|
||||
if (!global.context.unsafe_mode)
|
||||
diff --git a/src/st/st-texture-cache.c b/src/st/st-texture-cache.c
|
||||
index e03ec44619..ac19e98cf5 100644
|
||||
index 2c7601da1a..0df930ad43 100644
|
||||
--- a/src/st/st-texture-cache.c
|
||||
+++ b/src/st/st-texture-cache.c
|
||||
@@ -131,6 +131,16 @@ st_texture_cache_class_init (StTextureCacheClass *klass)
|
||||
@ -50,17 +50,17 @@ index e03ec44619..ac19e98cf5 100644
|
||||
static void
|
||||
st_texture_cache_evict_icons (StTextureCache *cache)
|
||||
diff --git a/src/st/st-texture-cache.h b/src/st/st-texture-cache.h
|
||||
index 7ca08ab34a..f600938047 100644
|
||||
index 4158298042..5a77165813 100644
|
||||
--- a/src/st/st-texture-cache.h
|
||||
+++ b/src/st/st-texture-cache.h
|
||||
@@ -42,6 +42,7 @@ typedef enum {
|
||||
@@ -43,6 +43,7 @@ typedef enum {
|
||||
} StTextureCachePolicy;
|
||||
|
||||
StTextureCache* st_texture_cache_get_default (void);
|
||||
+void st_texture_cache_clear (StTextureCache *cache);
|
||||
|
||||
ClutterActor *
|
||||
st_texture_cache_load_sliced_image (StTextureCache *cache,
|
||||
ClutterActor *st_texture_cache_load_gicon (StTextureCache *cache,
|
||||
StThemeNode *theme_node,
|
||||
--
|
||||
2.47.1
|
||||
2.51.1
|
||||
|
||||
|
||||
@ -1,64 +0,0 @@
|
||||
From 193b664c7daa2ea7707e8b7fba03afe07e2cbd2a Mon Sep 17 00:00:00 2001
|
||||
From: Joan Torres Lopez <joantolo@redhat.com>
|
||||
Date: Tue, 15 Jul 2025 11:27:01 +0200
|
||||
Subject: [PATCH] systemActions: Optionally allow restart/shutdown on lock
|
||||
screen
|
||||
|
||||
Support the new 'restart-enabled' setting from 'org.gnome.desktop.screensaver'
|
||||
to optionally allow restart/shutdown from the lock screen.
|
||||
|
||||
Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/1584
|
||||
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3797>
|
||||
---
|
||||
js/misc/systemActions.js | 9 ++++++++-
|
||||
1 file changed, 8 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/js/misc/systemActions.js b/js/misc/systemActions.js
|
||||
index a027a8134..c24d254b4 100644
|
||||
--- a/js/misc/systemActions.js
|
||||
+++ b/js/misc/systemActions.js
|
||||
@@ -12,10 +12,12 @@ import * as Screenshot from '../ui/screenshot.js';
|
||||
|
||||
const LOCKDOWN_SCHEMA = 'org.gnome.desktop.lockdown';
|
||||
const LOGIN_SCREEN_SCHEMA = 'org.gnome.login-screen';
|
||||
+const SCREENSAVER_SCHEMA = 'org.gnome.desktop.screensaver';
|
||||
const DISABLE_USER_SWITCH_KEY = 'disable-user-switching';
|
||||
const DISABLE_LOCK_SCREEN_KEY = 'disable-lock-screen';
|
||||
const DISABLE_LOG_OUT_KEY = 'disable-log-out';
|
||||
const DISABLE_RESTART_KEY = 'disable-restart-buttons';
|
||||
+const RESTART_ENABLED_KEY = 'restart-enabled';
|
||||
const ALWAYS_SHOW_LOG_OUT_KEY = 'always-show-log-out';
|
||||
|
||||
const POWER_OFF_ACTION_ID = 'power-off';
|
||||
@@ -153,6 +155,7 @@ const SystemActions = GObject.registerClass({
|
||||
this._loginScreenSettings = new Gio.Settings({schema_id: LOGIN_SCREEN_SCHEMA});
|
||||
this._lockdownSettings = new Gio.Settings({schema_id: LOCKDOWN_SCHEMA});
|
||||
this._orientationSettings = new Gio.Settings({schema_id: 'org.gnome.settings-daemon.peripherals.touchscreen'});
|
||||
+ this._screenSaverSettings = new Gio.Settings({schema_id: SCREENSAVER_SCHEMA});
|
||||
|
||||
this._session = new GnomeSession.SessionManager();
|
||||
this._loginManager = LoginManager.getLoginManager();
|
||||
@@ -182,6 +185,9 @@ const SystemActions = GObject.registerClass({
|
||||
this._lockdownSettings.connect(`changed::${DISABLE_LOG_OUT_KEY}`,
|
||||
() => this._updateHaveShutdown());
|
||||
|
||||
+ this._screenSaverSettings.connect(`changed::${RESTART_ENABLED_KEY}`,
|
||||
+ () => this._updateHaveShutdown());
|
||||
+
|
||||
this.forceUpdate();
|
||||
|
||||
this._orientationSettings.connect('changed::orientation-lock', () => {
|
||||
@@ -347,7 +353,8 @@ const SystemActions = GObject.registerClass({
|
||||
}
|
||||
|
||||
_updatePowerOff() {
|
||||
- let disabled = Main.sessionMode.isLocked ||
|
||||
+ let disabled = (Main.sessionMode.isLocked &&
|
||||
+ !this._screenSaverSettings.get_boolean(RESTART_ENABLED_KEY)) ||
|
||||
(Main.sessionMode.isGreeter &&
|
||||
this._loginScreenSettings.get_boolean(DISABLE_RESTART_KEY));
|
||||
this._actions.get(POWER_OFF_ACTION_ID).available = this._canHavePowerOff && !disabled;
|
||||
--
|
||||
2.49.0
|
||||
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
From 2c43d26950c709020ba78fdc2742adc4fd2841e5 Mon Sep 17 00:00:00 2001
|
||||
From a25806709e5cf5d73c2f261f89e8b7be1759d7c7 Mon Sep 17 00:00:00 2001
|
||||
From: Jakub Steiner <jimmac@gmail.com>
|
||||
Date: Tue, 20 Aug 2024 09:30:36 +0200
|
||||
Subject: [PATCH] theme: Welcome Illustration
|
||||
@ -9,7 +9,7 @@ Subject: [PATCH] theme: Welcome Illustration
|
||||
1 file changed, 106 insertions(+), 245 deletions(-)
|
||||
|
||||
diff --git a/data/theme/gnome-shell-start.svg b/data/theme/gnome-shell-start.svg
|
||||
index af139cf0d..609880493 100644
|
||||
index af139cf0da..6098804938 100644
|
||||
--- a/data/theme/gnome-shell-start.svg
|
||||
+++ b/data/theme/gnome-shell-start.svg
|
||||
@@ -1,67 +1,37 @@
|
||||
@ -459,5 +459,5 @@ index af139cf0d..609880493 100644
|
||||
+ inkscape:original="M 313.48633 103.79883 L 305.27734 108.99023 L 317.28516 113.2793 L 278.90234 137.55273 L 287.01172 144.30859 L 334.9043 114.01953 L 329.75391 109.73047 L 313.48633 103.79883 z M 339.08398 126.42578 C 336.58186 126.44685 334.02099 126.72082 331.4043 127.24805 C 326.21038 128.33537 321.15063 130.43744 316.22461 133.55273 C 311.3442 136.63918 307.7837 139.98905 305.54297 143.60352 C 303.38732 147.22202 302.62161 150.82875 303.24609 154.42383 C 303.95565 158.02294 306.10659 161.31916 309.69727 164.31055 C 313.32741 167.33481 317.52958 169.33062 322.30469 170.30078 C 327.16487 171.27497 332.19279 171.22013 337.38672 170.13281 C 342.66571 169.04952 347.74459 166.9634 352.625 163.87695 C 357.55102 160.76166 361.0924 157.39584 363.24805 153.77734 C 365.44315 150.19171 366.18612 146.59911 365.47656 143 C 364.85208 139.40492 362.72389 136.09458 359.09375 133.07031 C 355.50307 130.07892 351.27814 128.09723 346.41797 127.12305 C 344.03041 126.63796 341.58611 126.40471 339.08398 126.42578 z M 339.03711 134.75977 C 340.59668 134.65532 342.09264 134.71475 343.52344 134.9375 C 346.38503 135.38301 348.86185 136.47651 350.95312 138.21875 C 353.08387 139.99386 354.25653 141.94201 354.47266 144.06055 C 354.6888 146.17909 353.95735 148.37553 352.27734 150.65234 C 350.68241 152.93318 348.17475 155.15496 344.75391 157.31836 C 341.37867 159.45291 338.0017 160.95311 334.625 161.81641 C 331.28776 162.71258 328.18972 162.9377 325.32812 162.49219 C 322.46654 162.04668 319.96863 160.93528 317.83789 159.16016 C 315.74662 157.41792 314.59309 155.48768 314.37695 153.36914 C 314.16081 151.2506 314.87313 149.0382 316.51367 146.72852 C 318.19368 144.4517 320.72242 142.24587 324.09766 140.11133 C 327.5185 137.94792 330.87439 136.43177 334.16602 135.56445 C 335.85437 135.1328 337.47754 134.86421 339.03711 134.75977 z "
|
||||
+ d="m 314.52344,100.95703 a 3.0252571,3.0252571 0 0 0 -2.6543,0.28516 l -8.20898,5.1914 a 3.0252571,3.0252571 0 0 0 0.59961,5.40625 l 6.1621,2.20118 -33.13671,20.95507 a 3.0252571,3.0252571 0 0 0 -0.31836,4.88086 l 8.10937,6.75586 a 3.0252571,3.0252571 0 0 0 3.55274,0.23242 l 47.89257,-30.28906 a 3.0252571,3.0252571 0 0 0 0.31836,-4.88086 l -5.15039,-4.28906 a 3.0252571,3.0252571 0 0 0 -0.89843,-0.51758 z m 24.53515,22.44336 c -2.70552,0.0228 -5.45955,0.32018 -8.25195,0.88281 a 3.0252571,3.0252571 0 0 0 -0.0215,0.004 c -5.57359,1.1668 -10.9804,3.42211 -16.17774,6.70898 -5.15435,3.2597 -9.07893,6.89093 -11.63476,11.01368 a 3.0252571,3.0252571 0 0 0 -0.0293,0.0449 c -2.44678,4.10719 -3.43195,8.54475 -2.67774,12.88672 a 3.0252571,3.0252571 0 0 0 0.0117,0.0684 c 0.86616,4.39343 3.51054,8.31439 7.48438,11.625 4.00932,3.34015 8.71238,5.56847 13.9414,6.63085 a 3.0252571,3.0252571 0 0 0 0.008,0.002 c 5.27203,1.05674 10.73013,0.98909 16.2832,-0.17188 0.001,-2.8e-4 0.003,-0.002 0.004,-0.002 5.65232,-1.16046 11.08416,-3.3969 16.24414,-6.66016 5.19597,-3.28601 9.11209,-6.93484 11.59179,-11.08789 2.49319,-4.07791 3.46133,-8.54055 2.61524,-12.89062 -0.77549,-4.41697 -3.41096,-8.36912 -7.41992,-11.70899 -3.98043,-3.31609 -8.70902,-5.52412 -14.00977,-6.58789 -6.3e-4,-1.3e-4 -0.001,1.3e-4 -0.002,0 -2.59631,-0.52736 -5.25296,-0.7806 -7.95899,-0.75781 z m 0.17969,14.37695 c 1.35455,-0.0907 2.62538,-0.0376 3.82031,0.14844 2.38032,0.37058 4.29192,1.22835 5.95899,2.61719 1.71385,1.4278 2.3223,2.61846 2.44531,3.82422 0.12477,1.22298 -0.24192,2.62183 -1.61914,4.48828 a 3.0252571,3.0252571 0 0 0 -0.0449,0.0625 c -1.27029,1.81658 -3.46759,3.82347 -6.66211,5.84375 -3.14603,1.98959 -6.23089,3.34817 -9.26172,4.12305 a 3.0252571,3.0252571 0 0 0 -0.0352,0.01 c -3.00691,0.80747 -5.66623,0.98001 -8.04687,0.60938 -2.37037,-0.36904 -4.30499,-1.23959 -6.01953,-2.66797 -1.66738,-1.3891 -2.26205,-2.55145 -2.38672,-3.77344 -0.12591,-1.23411 0.24428,-2.66937 1.58203,-4.56055 1.37458,-1.85462 3.60235,-3.84584 6.74609,-5.83398 3.20097,-2.02436 6.27281,-3.3982 9.21094,-4.17383 1.52545,-0.3894 2.96138,-0.62632 4.3125,-0.7168 z" /></g></g></svg>
|
||||
--
|
||||
2.46.2
|
||||
2.51.1
|
||||
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
From 15df1086028087e5a81830323137a8730d2c5888 Mon Sep 17 00:00:00 2001
|
||||
From 29f77afc6d76cadf3f0cac7b0e741049af21e86d Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Tue, 14 Mar 2017 17:04:36 +0100
|
||||
Subject: [PATCH] windowMenu: Bring back workspaces submenu for static
|
||||
@ -13,10 +13,10 @@ are used.
|
||||
1 file changed, 17 insertions(+)
|
||||
|
||||
diff --git a/js/ui/windowMenu.js b/js/ui/windowMenu.js
|
||||
index c69c183d7c..2db3962012 100644
|
||||
index c140dee4dd..6e28244723 100644
|
||||
--- a/js/ui/windowMenu.js
|
||||
+++ b/js/ui/windowMenu.js
|
||||
@@ -153,6 +153,23 @@ export class WindowMenu extends PopupMenu.PopupMenu {
|
||||
@@ -138,6 +138,23 @@ export class WindowMenu extends PopupMenu.PopupMenu {
|
||||
window.change_workspace(workspace.get_neighbor(dir));
|
||||
});
|
||||
}
|
||||
@ -41,5 +41,5 @@ index c69c183d7c..2db3962012 100644
|
||||
}
|
||||
|
||||
--
|
||||
2.45.2
|
||||
2.51.1
|
||||
|
||||
|
||||
@ -0,0 +1,46 @@
|
||||
From 100b2139c689e8e9ef8095cdd7da8eb016a3f53f Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Thu, 13 Nov 2025 12:57:58 +0100
|
||||
Subject: [PATCH 2/2] Reapply "main: Notify gnome-session when we're ready"
|
||||
|
||||
This reverts commit d697bdceaefeae49ad0e03df7352884899c3e14a.
|
||||
---
|
||||
js/ui/main.js | 15 +++++++++++++++
|
||||
1 file changed, 15 insertions(+)
|
||||
|
||||
diff --git a/js/ui/main.js b/js/ui/main.js
|
||||
index bb6d8f6723..7e1b84d694 100644
|
||||
--- a/js/ui/main.js
|
||||
+++ b/js/ui/main.js
|
||||
@@ -330,6 +330,7 @@ async function _initializeUI() {
|
||||
GLib.idle_add(GLib.PRIORITY_DEFAULT, () => {
|
||||
Shell.util_sd_notify();
|
||||
global.context.notify_ready();
|
||||
+ _notifyGnomeSessionReady();
|
||||
return GLib.SOURCE_REMOVE;
|
||||
});
|
||||
|
||||
@@ -394,6 +395,20 @@ async function _initializeUI() {
|
||||
});
|
||||
}
|
||||
|
||||
+async function _notifyGnomeSessionReady() {
|
||||
+ try {
|
||||
+ let params = GLib.Variant.new('(ss)', ['org.gnome.Shell.desktop', '']);
|
||||
+ await Gio.DBus.session.call(
|
||||
+ 'org.gnome.SessionManager',
|
||||
+ '/org/gnome/SessionManager',
|
||||
+ 'org.gnome.SessionManager',
|
||||
+ 'RegisterClient', params, null,
|
||||
+ Gio.DBusCallFlags.NONE, -1, null);
|
||||
+ } catch (e) {
|
||||
+ log(`Error notifying gnome-session that we're ready: ${e.message}`);
|
||||
+ }
|
||||
+}
|
||||
+
|
||||
function _handleShowWelcomeScreen() {
|
||||
const lastShownVersion = global.settings.get_string(WELCOME_DIALOG_LAST_SHOWN_VERSION);
|
||||
if (Util.GNOMEversionCompare(WELCOME_DIALOG_LAST_TOUR_CHANGE, lastShownVersion) > 0) {
|
||||
--
|
||||
2.51.1
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
From 8a4efef39a0f48371c632d449688f29d06b9eed7 Mon Sep 17 00:00:00 2001
|
||||
From 2af9a2832992b7b89465b47cf9adb979b8d6b087 Mon Sep 17 00:00:00 2001
|
||||
From: Ray Strode <rstrode@redhat.com>
|
||||
Date: Wed, 30 Sep 2015 12:51:24 -0400
|
||||
Subject: [PATCH 1/3] authPrompt: don't fade out auth messages if user types
|
||||
@ -12,10 +12,10 @@ front, before a password is asked.
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/js/gdm/authPrompt.js b/js/gdm/authPrompt.js
|
||||
index 8a46559d90..9309f60886 100644
|
||||
index 800e2f1851..7ee8186dcc 100644
|
||||
--- a/js/gdm/authPrompt.js
|
||||
+++ b/js/gdm/authPrompt.js
|
||||
@@ -211,7 +211,7 @@ export const AuthPrompt = GObject.registerClass({
|
||||
@@ -217,7 +217,7 @@ export const AuthPrompt = GObject.registerClass({
|
||||
|
||||
[this._textEntry, this._passwordEntry].forEach(entry => {
|
||||
entry.clutter_text.connect('text-changed', () => {
|
||||
@ -25,10 +25,10 @@ index 8a46559d90..9309f60886 100644
|
||||
});
|
||||
|
||||
--
|
||||
2.45.2
|
||||
2.51.1
|
||||
|
||||
|
||||
From 007bbb694d4f30175caecbc9ada91515634bfd0b Mon Sep 17 00:00:00 2001
|
||||
From 691685e9582e23cce382841c1d66c44ea56ceb33 Mon Sep 17 00:00:00 2001
|
||||
From: Ray Strode <rstrode@redhat.com>
|
||||
Date: Wed, 30 Sep 2015 14:36:33 -0400
|
||||
Subject: [PATCH 2/3] authPrompt: don't spin unless answering question
|
||||
@ -38,10 +38,10 @@ Subject: [PATCH 2/3] authPrompt: don't spin unless answering question
|
||||
1 file changed, 5 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git a/js/gdm/authPrompt.js b/js/gdm/authPrompt.js
|
||||
index 9309f60886..3e72668967 100644
|
||||
index 7ee8186dcc..97b276dbf9 100644
|
||||
--- a/js/gdm/authPrompt.js
|
||||
+++ b/js/gdm/authPrompt.js
|
||||
@@ -275,13 +275,14 @@ export const AuthPrompt = GObject.registerClass({
|
||||
@@ -281,13 +281,14 @@ export const AuthPrompt = GObject.registerClass({
|
||||
this.verificationStatus = AuthPromptStatus.VERIFICATION_IN_PROGRESS;
|
||||
this.updateSensitivity(false);
|
||||
|
||||
@ -61,10 +61,10 @@ index 9309f60886..3e72668967 100644
|
||||
this.emit('next');
|
||||
}
|
||||
--
|
||||
2.45.2
|
||||
2.51.1
|
||||
|
||||
|
||||
From 92f66a5ff91e47d46a48d7ee51c0808f7ce1eaf9 Mon Sep 17 00:00:00 2001
|
||||
From 60c374af34ec60a3aa0403888d70a835774209af Mon Sep 17 00:00:00 2001
|
||||
From: Ray Strode <rstrode@redhat.com>
|
||||
Date: Mon, 5 Oct 2015 15:26:18 -0400
|
||||
Subject: [PATCH 3/3] authPrompt: stop accepting preemptive answer if user
|
||||
@ -82,10 +82,10 @@ all.
|
||||
1 file changed, 36 insertions(+)
|
||||
|
||||
diff --git a/js/gdm/authPrompt.js b/js/gdm/authPrompt.js
|
||||
index 3e72668967..254b4dbb88 100644
|
||||
index 97b276dbf9..2bf722b140 100644
|
||||
--- a/js/gdm/authPrompt.js
|
||||
+++ b/js/gdm/authPrompt.js
|
||||
@@ -70,6 +70,8 @@ export const AuthPrompt = GObject.registerClass({
|
||||
@@ -69,6 +69,8 @@ export const AuthPrompt = GObject.registerClass({
|
||||
this._defaultButtonWellActor = null;
|
||||
this._cancelledRetries = 0;
|
||||
|
||||
@ -94,7 +94,7 @@ index 3e72668967..254b4dbb88 100644
|
||||
let reauthenticationOnly;
|
||||
if (this._mode === AuthPromptMode.UNLOCK_ONLY)
|
||||
reauthenticationOnly = true;
|
||||
@@ -127,8 +129,14 @@ export const AuthPrompt = GObject.registerClass({
|
||||
@@ -130,8 +132,14 @@ export const AuthPrompt = GObject.registerClass({
|
||||
}
|
||||
|
||||
_onDestroy() {
|
||||
@ -108,8 +108,8 @@ index 3e72668967..254b4dbb88 100644
|
||||
+
|
||||
this._userVerifier.destroy();
|
||||
this._userVerifier = null;
|
||||
}
|
||||
@@ -282,6 +290,11 @@ export const AuthPrompt = GObject.registerClass({
|
||||
this._entry = null;
|
||||
@@ -288,6 +296,11 @@ export const AuthPrompt = GObject.registerClass({
|
||||
this._userVerifier.answerQuery(this._queryingService, this._entry.text);
|
||||
} else {
|
||||
this._preemptiveAnswer = this._entry.text;
|
||||
@ -121,7 +121,7 @@ index 3e72668967..254b4dbb88 100644
|
||||
}
|
||||
|
||||
this.emit('next');
|
||||
@@ -493,6 +506,11 @@ export const AuthPrompt = GObject.registerClass({
|
||||
@@ -510,6 +523,11 @@ export const AuthPrompt = GObject.registerClass({
|
||||
}
|
||||
|
||||
setQuestion(question) {
|
||||
@ -133,7 +133,7 @@ index 3e72668967..254b4dbb88 100644
|
||||
this._entry.hint_text = question;
|
||||
|
||||
this._authList.hide();
|
||||
@@ -614,6 +632,19 @@ export const AuthPrompt = GObject.registerClass({
|
||||
@@ -639,6 +657,19 @@ export const AuthPrompt = GObject.registerClass({
|
||||
this._updateEntry(false);
|
||||
}
|
||||
|
||||
@ -153,18 +153,18 @@ index 3e72668967..254b4dbb88 100644
|
||||
reset() {
|
||||
let oldStatus = this.verificationStatus;
|
||||
this.verificationStatus = AuthPromptStatus.NOT_VERIFYING;
|
||||
@@ -621,6 +652,11 @@ export const AuthPrompt = GObject.registerClass({
|
||||
@@ -646,6 +677,11 @@ export const AuthPrompt = GObject.registerClass({
|
||||
this.cancelButton.can_focus = this._hasCancelButton;
|
||||
this._preemptiveAnswer = null;
|
||||
|
||||
+ if (this._preemptiveAnswerWatchId)
|
||||
+ this._idleMonitor.remove_watch(this._preemptiveAnswerWatchId);
|
||||
+ this._preemptiveAnswerWatchId = this._idleMonitor.add_idle_watch(500,
|
||||
+ this._preemptiveAnswerWatchId = this._idleMonitor.add_idle_watch(3000,
|
||||
+ this._onUserStoppedTypePreemptiveAnswer.bind(this));
|
||||
+
|
||||
if (this._userVerifier)
|
||||
this._userVerifier.cancel();
|
||||
|
||||
--
|
||||
2.45.2
|
||||
2.51.1
|
||||
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
From eaa7217db15a28e88ce0b5a84827c306148561ca Mon Sep 17 00:00:00 2001
|
||||
From 54a9bed1caa83ee00ca95f3431a3ee2a15a1ee82 Mon Sep 17 00:00:00 2001
|
||||
From: Ray Strode <rstrode@redhat.com>
|
||||
Date: Mon, 28 Sep 2015 10:57:02 -0400
|
||||
Subject: [PATCH 1/3] smartcardManager: add way to detect if user logged using
|
||||
@ -16,10 +16,10 @@ This commit adds the necessary api to detect that case.
|
||||
1 file changed, 7 insertions(+)
|
||||
|
||||
diff --git a/js/misc/smartcardManager.js b/js/misc/smartcardManager.js
|
||||
index 32573cd384..6c48c80a19 100644
|
||||
index b886110d91..51471e51d4 100644
|
||||
--- a/js/misc/smartcardManager.js
|
||||
+++ b/js/misc/smartcardManager.js
|
||||
@@ -118,4 +118,11 @@ class SmartcardManager extends Signals.EventEmitter {
|
||||
@@ -116,4 +116,11 @@ class SmartcardManager extends Signals.EventEmitter {
|
||||
|
||||
return true;
|
||||
}
|
||||
@ -32,10 +32,10 @@ index 32573cd384..6c48c80a19 100644
|
||||
+ }
|
||||
}
|
||||
--
|
||||
2.45.2
|
||||
2.51.1
|
||||
|
||||
|
||||
From d7ef26d7b9d352232c9e0a24a04bcfcf6eee7d9a Mon Sep 17 00:00:00 2001
|
||||
From bdbed658d7a2fa48b9e7195691f0db3c8f4868e3 Mon Sep 17 00:00:00 2001
|
||||
From: Ray Strode <rstrode@redhat.com>
|
||||
Date: Mon, 28 Sep 2015 19:56:53 -0400
|
||||
Subject: [PATCH 2/3] gdm: only unlock with smartcard, if smartcard used for
|
||||
@ -48,7 +48,7 @@ gets used for unlock, too.
|
||||
1 file changed, 5 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/js/gdm/util.js b/js/gdm/util.js
|
||||
index c9c040beb7..c0d8852880 100644
|
||||
index aced46e78c..28190660e8 100644
|
||||
--- a/js/gdm/util.js
|
||||
+++ b/js/gdm/util.js
|
||||
@@ -465,6 +465,8 @@ export class ShellUserVerifier extends Signals.EventEmitter {
|
||||
@ -72,10 +72,10 @@ index c9c040beb7..c0d8852880 100644
|
||||
else if (this._smartcardManager)
|
||||
return SMARTCARD_SERVICE_NAME;
|
||||
--
|
||||
2.45.2
|
||||
2.51.1
|
||||
|
||||
|
||||
From 9bff98c2757e4591035e408aa9cee703cec74bdf Mon Sep 17 00:00:00 2001
|
||||
From 2cae726f8e9887c5f49254f9af39bada00e81ca7 Mon Sep 17 00:00:00 2001
|
||||
From: Ray Strode <rstrode@redhat.com>
|
||||
Date: Mon, 28 Sep 2015 19:57:36 -0400
|
||||
Subject: [PATCH 3/3] gdm: update default service when smartcard inserted
|
||||
@ -88,7 +88,7 @@ after we get a smartcard insertion event.
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/js/gdm/util.js b/js/gdm/util.js
|
||||
index c0d8852880..430af4d8ef 100644
|
||||
index 28190660e8..c87690f859 100644
|
||||
--- a/js/gdm/util.js
|
||||
+++ b/js/gdm/util.js
|
||||
@@ -490,6 +490,8 @@ export class ShellUserVerifier extends Signals.EventEmitter {
|
||||
@ -101,5 +101,5 @@ index c0d8852880..430af4d8ef 100644
|
||||
}
|
||||
}
|
||||
--
|
||||
2.45.2
|
||||
2.51.1
|
||||
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
From 04bf0729ed6ae75736e297a10603bcb0a564cb28 Mon Sep 17 00:00:00 2001
|
||||
From cbb32cb80221d04121d4942bf41a23dd44ada9a9 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Tue, 9 Jun 2020 19:42:21 +0200
|
||||
Subject: [PATCH 1/2] popupMenu: Guard against non-menu-item children
|
||||
@ -9,10 +9,10 @@ This avoid a harmless but annoying warning.
|
||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/js/ui/popupMenu.js b/js/ui/popupMenu.js
|
||||
index b6ad545087..cbbcfea1ff 100644
|
||||
index 0426ce5452..2c882c1067 100644
|
||||
--- a/js/ui/popupMenu.js
|
||||
+++ b/js/ui/popupMenu.js
|
||||
@@ -951,7 +951,8 @@ export class PopupMenuBase extends Signals.EventEmitter {
|
||||
@@ -967,7 +967,8 @@ export class PopupMenuBase extends Signals.EventEmitter {
|
||||
}
|
||||
|
||||
_getMenuItems() {
|
||||
@ -23,10 +23,10 @@ index b6ad545087..cbbcfea1ff 100644
|
||||
});
|
||||
}
|
||||
--
|
||||
2.45.2
|
||||
2.51.1
|
||||
|
||||
|
||||
From cffe984d9b85494fcf34500e78875b66c1cec534 Mon Sep 17 00:00:00 2001
|
||||
From 406c67ea0877384d85e5dcb5be644acf491cbd4d Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Tue, 9 Jun 2020 19:48:06 +0200
|
||||
Subject: [PATCH 2/2] st/shadow: Check pipeline when painting
|
||||
@ -38,10 +38,10 @@ called before paint() or that the pipeline was created successfully.
|
||||
1 file changed, 6 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/src/st/st-shadow.c b/src/st/st-shadow.c
|
||||
index a406b61532..574445aeac 100644
|
||||
index 0e7908ac1d..280562b5b7 100644
|
||||
--- a/src/st/st-shadow.c
|
||||
+++ b/src/st/st-shadow.c
|
||||
@@ -294,9 +294,10 @@ st_shadow_helper_paint (StShadowHelper *helper,
|
||||
@@ -288,9 +288,10 @@ st_shadow_helper_paint (StShadowHelper *helper,
|
||||
ClutterActorBox *actor_box,
|
||||
uint8_t paint_opacity)
|
||||
{
|
||||
@ -58,5 +58,5 @@ index a406b61532..574445aeac 100644
|
||||
+ paint_opacity);
|
||||
}
|
||||
--
|
||||
2.45.2
|
||||
2.51.1
|
||||
|
||||
|
||||
@ -1,232 +0,0 @@
|
||||
From f328eee88c4e700a29625e87fd6fc997a138c66b Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Fri, 22 Nov 2024 19:23:59 +0100
|
||||
Subject: [PATCH 1/3] loginDialog: Split out getBannerText() helper
|
||||
|
||||
The new methods will make it easier to add alternative sources
|
||||
for the banner text.
|
||||
|
||||
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3558>
|
||||
---
|
||||
js/gdm/loginDialog.js | 13 ++++++++++---
|
||||
1 file changed, 10 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/js/gdm/loginDialog.js b/js/gdm/loginDialog.js
|
||||
index 27baae83ad..c3c397c0d1 100644
|
||||
--- a/js/gdm/loginDialog.js
|
||||
+++ b/js/gdm/loginDialog.js
|
||||
@@ -873,11 +873,18 @@ export const LoginDialog = GObject.registerClass({
|
||||
this._authPrompt.cancelButton.visible = cancelVisible;
|
||||
}
|
||||
|
||||
+ _getBannerText() {
|
||||
+ const enabled = this._settings.get_boolean(GdmUtil.BANNER_MESSAGE_KEY);
|
||||
+ if (!enabled)
|
||||
+ return null;
|
||||
+
|
||||
+ return this._settings.get_string(GdmUtil.BANNER_MESSAGE_TEXT_KEY);
|
||||
+ }
|
||||
+
|
||||
_updateBanner() {
|
||||
- let enabled = this._settings.get_boolean(GdmUtil.BANNER_MESSAGE_KEY);
|
||||
- let text = this._settings.get_string(GdmUtil.BANNER_MESSAGE_TEXT_KEY);
|
||||
+ const text = this._getBannerText();
|
||||
|
||||
- if (enabled && text) {
|
||||
+ if (text) {
|
||||
this._bannerLabel.set_text(text);
|
||||
this._bannerLabel.show();
|
||||
} else {
|
||||
--
|
||||
2.48.1
|
||||
|
||||
|
||||
From 5f92c12c727bd447d7e539b1e6c8f3ac6ddf715a Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Fri, 22 Nov 2024 19:36:42 +0100
|
||||
Subject: [PATCH 2/3] loginDialog: Update banner asynchronously
|
||||
|
||||
We will soon allow reading the banner text from a file. Prepare
|
||||
for that by making the method asynchronous.
|
||||
|
||||
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3558>
|
||||
---
|
||||
js/gdm/loginDialog.js | 15 +++++++++------
|
||||
1 file changed, 9 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/js/gdm/loginDialog.js b/js/gdm/loginDialog.js
|
||||
index c3c397c0d1..125cf299fa 100644
|
||||
--- a/js/gdm/loginDialog.js
|
||||
+++ b/js/gdm/loginDialog.js
|
||||
@@ -505,9 +505,9 @@ export const LoginDialog = GObject.registerClass({
|
||||
this._settings = new Gio.Settings({schema_id: GdmUtil.LOGIN_SCREEN_SCHEMA});
|
||||
|
||||
this._settings.connect(`changed::${GdmUtil.BANNER_MESSAGE_KEY}`,
|
||||
- this._updateBanner.bind(this));
|
||||
+ () => this._updateBanner().catch(logError));
|
||||
this._settings.connect(`changed::${GdmUtil.BANNER_MESSAGE_TEXT_KEY}`,
|
||||
- this._updateBanner.bind(this));
|
||||
+ () => this._updateBanner().catch(logError));
|
||||
this._settings.connect(`changed::${GdmUtil.DISABLE_USER_LIST_KEY}`,
|
||||
this._updateDisableUserList.bind(this));
|
||||
this._settings.connect(`changed::${GdmUtil.LOGO_KEY}`,
|
||||
@@ -576,7 +576,7 @@ export const LoginDialog = GObject.registerClass({
|
||||
this._bannerLabel.clutter_text.line_wrap = true;
|
||||
this._bannerLabel.clutter_text.ellipsize = Pango.EllipsizeMode.NONE;
|
||||
bannerBox.add_child(this._bannerLabel);
|
||||
- this._updateBanner();
|
||||
+ this._updateBanner().catch(logError);
|
||||
|
||||
this._sessionMenuButton = new SessionMenuButton();
|
||||
this._sessionMenuButton.connect('session-activated',
|
||||
@@ -873,16 +873,19 @@ export const LoginDialog = GObject.registerClass({
|
||||
this._authPrompt.cancelButton.visible = cancelVisible;
|
||||
}
|
||||
|
||||
- _getBannerText() {
|
||||
+ async _getBannerText() {
|
||||
const enabled = this._settings.get_boolean(GdmUtil.BANNER_MESSAGE_KEY);
|
||||
if (!enabled)
|
||||
return null;
|
||||
|
||||
+ // placeholder
|
||||
+ await false;
|
||||
+
|
||||
return this._settings.get_string(GdmUtil.BANNER_MESSAGE_TEXT_KEY);
|
||||
}
|
||||
|
||||
- _updateBanner() {
|
||||
- const text = this._getBannerText();
|
||||
+ async _updateBanner() {
|
||||
+ const text = await this._getBannerText();
|
||||
|
||||
if (text) {
|
||||
this._bannerLabel.set_text(text);
|
||||
--
|
||||
2.48.1
|
||||
|
||||
|
||||
From a73a4f8455b1374b38724a532137a9b614a7fb19 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Fri, 22 Nov 2024 19:17:44 +0100
|
||||
Subject: [PATCH 3/3] loginDialog: Support loading banner message from file
|
||||
|
||||
Support the new `banner-message-path` and `banner-message-source`
|
||||
settings, which allows loading the banner message from a path
|
||||
instead of GSettings. This is mainly useful for `/etc/motd` and
|
||||
similar mechanisms, to show the same message for both graphical
|
||||
and non-graphical logins.
|
||||
|
||||
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3558>
|
||||
---
|
||||
js/gdm/loginDialog.js | 53 +++++++++++++++++++++++++++++++++++++++++--
|
||||
js/gdm/util.js | 2 ++
|
||||
2 files changed, 53 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/js/gdm/loginDialog.js b/js/gdm/loginDialog.js
|
||||
index 125cf299fa..fa91615026 100644
|
||||
--- a/js/gdm/loginDialog.js
|
||||
+++ b/js/gdm/loginDialog.js
|
||||
@@ -46,6 +46,8 @@ const _SCROLL_ANIMATION_TIME = 500;
|
||||
const _TIMED_LOGIN_IDLE_THRESHOLD = 5.0;
|
||||
const _CONFLICTING_SESSION_DIALOG_TIMEOUT = 60;
|
||||
|
||||
+Gio._promisify(Gio.File.prototype, 'load_contents_async');
|
||||
+
|
||||
export const UserListItem = GObject.registerClass({
|
||||
Signals: {'activate': {}},
|
||||
}, class UserListItem extends St.Button {
|
||||
@@ -508,6 +510,16 @@ export const LoginDialog = GObject.registerClass({
|
||||
() => this._updateBanner().catch(logError));
|
||||
this._settings.connect(`changed::${GdmUtil.BANNER_MESSAGE_TEXT_KEY}`,
|
||||
() => this._updateBanner().catch(logError));
|
||||
+ this._settings.connect(`changed::${GdmUtil.BANNER_MESSAGE_SOURCE_KEY}`,
|
||||
+ () => {
|
||||
+ if (this._updateBannerMessageFile())
|
||||
+ this._updateBanner().catch(logError);
|
||||
+ });
|
||||
+ this._settings.connect(`changed::${GdmUtil.BANNER_MESSAGE_PATH_KEY}`,
|
||||
+ () => {
|
||||
+ if (this._updateBannerMessageFile())
|
||||
+ this._updateBanner().catch(logError);
|
||||
+ });
|
||||
this._settings.connect(`changed::${GdmUtil.DISABLE_USER_LIST_KEY}`,
|
||||
this._updateDisableUserList.bind(this));
|
||||
this._settings.connect(`changed::${GdmUtil.LOGO_KEY}`,
|
||||
@@ -576,6 +588,8 @@ export const LoginDialog = GObject.registerClass({
|
||||
this._bannerLabel.clutter_text.line_wrap = true;
|
||||
this._bannerLabel.clutter_text.ellipsize = Pango.EllipsizeMode.NONE;
|
||||
bannerBox.add_child(this._bannerLabel);
|
||||
+
|
||||
+ this._updateBannerMessageFile();
|
||||
this._updateBanner().catch(logError);
|
||||
|
||||
this._sessionMenuButton = new SessionMenuButton();
|
||||
@@ -873,13 +887,48 @@ export const LoginDialog = GObject.registerClass({
|
||||
this._authPrompt.cancelButton.visible = cancelVisible;
|
||||
}
|
||||
|
||||
+ _updateBannerMessageFile() {
|
||||
+ const path = this._settings.get_string(GdmUtil.BANNER_MESSAGE_SOURCE_KEY) === 'file'
|
||||
+ ? this._settings.get_string(GdmUtil.BANNER_MESSAGE_PATH_KEY)
|
||||
+ : null;
|
||||
+ const file = path
|
||||
+ ? Gio.File.new_for_path(path)
|
||||
+ : null;
|
||||
+
|
||||
+ if (!file && !this._bannerMessageFile)
|
||||
+ return false;
|
||||
+
|
||||
+ if (file && this._bannerMessageFile && this._bannerMessageFile.equal(file))
|
||||
+ return false;
|
||||
+
|
||||
+ this._bannerMessageMonitor?.disconnectObject(this);
|
||||
+ this._bannerMessageMonitor = null;
|
||||
+
|
||||
+ this._bannerMessageFile = file;
|
||||
+
|
||||
+ if (file) {
|
||||
+ this._bannerMessageMonitor = file.monitor_file(Gio.FileMonitorFlags.NONE, null);
|
||||
+ this._bannerMessageMonitor.connectObject(
|
||||
+ 'changed', () => this._updateBanner().catch(logError), this);
|
||||
+ }
|
||||
+
|
||||
+ return true;
|
||||
+ }
|
||||
+
|
||||
async _getBannerText() {
|
||||
const enabled = this._settings.get_boolean(GdmUtil.BANNER_MESSAGE_KEY);
|
||||
if (!enabled)
|
||||
return null;
|
||||
|
||||
- // placeholder
|
||||
- await false;
|
||||
+ if (this._bannerMessageFile) {
|
||||
+ try {
|
||||
+ const [contents] = await this._bannerMessageFile.load_contents_async(null);
|
||||
+ return new TextDecoder().decode(contents);
|
||||
+ } catch (e) {
|
||||
+ console.error(`Failed to read banner from ${this._bannerMessageFile.get_path()}: ${e.message}`);
|
||||
+ return null;
|
||||
+ }
|
||||
+ }
|
||||
|
||||
return this._settings.get_string(GdmUtil.BANNER_MESSAGE_TEXT_KEY);
|
||||
}
|
||||
diff --git a/js/gdm/util.js b/js/gdm/util.js
|
||||
index 1e0154f36f..f6b797c321 100644
|
||||
--- a/js/gdm/util.js
|
||||
+++ b/js/gdm/util.js
|
||||
@@ -33,7 +33,9 @@ export const PASSWORD_AUTHENTICATION_KEY = 'enable-password-authentication';
|
||||
export const FINGERPRINT_AUTHENTICATION_KEY = 'enable-fingerprint-authentication';
|
||||
export const SMARTCARD_AUTHENTICATION_KEY = 'enable-smartcard-authentication';
|
||||
export const BANNER_MESSAGE_KEY = 'banner-message-enable';
|
||||
+export const BANNER_MESSAGE_SOURCE_KEY = 'banner-message-source';
|
||||
export const BANNER_MESSAGE_TEXT_KEY = 'banner-message-text';
|
||||
+export const BANNER_MESSAGE_PATH_KEY = 'banner-message-path';
|
||||
export const ALLOWED_FAILURES_KEY = 'allowed-failures';
|
||||
|
||||
export const LOGO_KEY = 'logo';
|
||||
--
|
||||
2.48.1
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
From 8fcaf1708fee86b1c16c9749dc1794be5a2a86fd Mon Sep 17 00:00:00 2001
|
||||
From f8340bf01c7520af83a3098e7c574c67facbde1e Mon Sep 17 00:00:00 2001
|
||||
From: rpm-build <rpm-build>
|
||||
Date: Mon, 28 Feb 2022 10:27:09 -0500
|
||||
Subject: [PATCH] data: Enable logo extension out of the box
|
||||
@ -12,7 +12,7 @@ This commit makes sure it gets enabled out of the box.
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/data/org.gnome.shell.gschema.xml.in b/data/org.gnome.shell.gschema.xml.in
|
||||
index 3dd9d2d86b..fe1e266f8c 100644
|
||||
index 9a55ee71db..1f9862a779 100644
|
||||
--- a/data/org.gnome.shell.gschema.xml.in
|
||||
+++ b/data/org.gnome.shell.gschema.xml.in
|
||||
@@ -12,7 +12,7 @@
|
||||
@ -25,5 +25,5 @@ index 3dd9d2d86b..fe1e266f8c 100644
|
||||
<description>
|
||||
GNOME Shell extensions have a UUID property; this key lists extensions
|
||||
--
|
||||
2.45.2
|
||||
2.51.1
|
||||
|
||||
|
||||
@ -1,35 +1,22 @@
|
||||
From 8a6298a1e7f7d46abf86ddec8ca2c8edbe4a589f Mon Sep 17 00:00:00 2001
|
||||
From 723135b8a757c02e7f598a0a95f99287dda805cb Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 17 Sep 2014 07:11:12 +0200
|
||||
Subject: [PATCH] Replace Web with Firefox in default favorites
|
||||
|
||||
---
|
||||
data/default-apps/dash.txt | 2 +-
|
||||
js/ui/appFavorites.js | 1 +
|
||||
2 files changed, 2 insertions(+), 1 deletion(-)
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/data/default-apps/dash.txt b/data/default-apps/dash.txt
|
||||
index d0c2c21eb8..a926311701 100644
|
||||
index 3687574be8..cdd8ef04e3 100644
|
||||
--- a/data/default-apps/dash.txt
|
||||
+++ b/data/default-apps/dash.txt
|
||||
@@ -1,4 +1,4 @@
|
||||
-org.gnome.Epiphany.desktop
|
||||
+org.mozilla.Firefox.desktop
|
||||
org.gnome.Calendar.desktop
|
||||
org.gnome.Music.desktop
|
||||
gnome.Nautilus.desktop
|
||||
diff --git a/js/ui/appFavorites.js b/js/ui/appFavorites.js
|
||||
index e3a76dce96..b6525f3cc9 100644
|
||||
--- a/js/ui/appFavorites.js
|
||||
+++ b/js/ui/appFavorites.js
|
||||
@@ -48,6 +48,7 @@ const RENAMED_DESKTOP_IDS = {
|
||||
'gnotski.desktop': 'org.gnome.Klotski.desktop',
|
||||
'gtali.desktop': 'org.gnome.Tali.desktop',
|
||||
'iagno.desktop': 'org.gnome.Reversi.desktop',
|
||||
+ 'firefox.desktop': 'org.mozilla.firefox.desktop',
|
||||
'nautilus.desktop': 'org.gnome.Nautilus.desktop',
|
||||
'org.gnome.gnome-2048.desktop': 'org.gnome.TwentyFortyEight.desktop',
|
||||
'org.gnome.taquin.desktop': 'org.gnome.Taquin.desktop',
|
||||
org.gnome.Nautilus.desktop
|
||||
org.gnome.Software.desktop
|
||||
--
|
||||
2.48.1
|
||||
2.51.1
|
||||
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
From c20b996f0cf89d4620d01fa777787b80b15c8a37 Mon Sep 17 00:00:00 2001
|
||||
From 578b2f5c52ab55ae1839f9d055c56762f13e01cf Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Thu, 9 Mar 2017 14:44:32 +0100
|
||||
Subject: [PATCH] appFavorites: Add terminal
|
||||
@ -8,16 +8,16 @@ Subject: [PATCH] appFavorites: Add terminal
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/data/default-apps/dash.txt b/data/default-apps/dash.txt
|
||||
index a926311701..5178256f6a 100644
|
||||
index cdd8ef04e3..4ab3f2913f 100644
|
||||
--- a/data/default-apps/dash.txt
|
||||
+++ b/data/default-apps/dash.txt
|
||||
@@ -3,5 +3,6 @@ org.gnome.Calendar.desktop
|
||||
org.gnome.Music.desktop
|
||||
gnome.Nautilus.desktop
|
||||
@@ -2,5 +2,6 @@ org.mozilla.Firefox.desktop
|
||||
org.gnome.Calendar.desktop
|
||||
org.gnome.Nautilus.desktop
|
||||
org.gnome.Software.desktop
|
||||
+org.gnome.Ptyxis.desktop
|
||||
org.gnome.TextEditor.desktop
|
||||
org.gnome.Calculator.desktop
|
||||
--
|
||||
2.48.1
|
||||
2.51.1
|
||||
|
||||
|
||||
121
gnome-shell.spec
121
gnome-shell.spec
@ -2,7 +2,7 @@
|
||||
## (rpmautospec version 0.6.5)
|
||||
## RPMAUTOSPEC: autorelease, autochangelog
|
||||
%define autorelease(e:s:pb:n) %{?-p:0.}%{lua:
|
||||
release_number = 3;
|
||||
release_number = 2;
|
||||
base_release_number = tonumber(rpm.expand("%{?-b*}%{!?-b:1}"));
|
||||
print(release_number + base_release_number - 1);
|
||||
}%{?-e:.%{-e*}}%{?-s:.%{-s*}}%{!?-n:%{?dist}}
|
||||
@ -18,7 +18,7 @@
|
||||
%endif
|
||||
|
||||
Name: gnome-shell
|
||||
Version: 47.4
|
||||
Version: 49.4
|
||||
Release: %autorelease
|
||||
Summary: Window management and application launching for GNOME
|
||||
|
||||
@ -28,21 +28,32 @@ Source0: https://download.gnome.org/sources/gnome-shell/%{major_version}/
|
||||
|
||||
# Replace Epiphany with Firefox in the default favourite apps list, etc
|
||||
# and enable background extension by default
|
||||
Patch: tweak-app-defaults.patch
|
||||
Patch: gnome-shell-favourite-apps-firefox.patch
|
||||
Patch: gnome-shell-favourite-apps-terminal.patch
|
||||
Patch: gnome-shell-enabled-extensions-background-logos.patch
|
||||
|
||||
# Some users might have a broken PAM config, so we really need this
|
||||
# downstream patch to stop trying on configuration errors.
|
||||
Patch: 0001-gdm-Work-around-failing-fingerprint-auth.patch
|
||||
# girpository-2.0 port would require updates to both gjs and glib2,
|
||||
# so revert it
|
||||
Patch: revert-gir-2.0-port.patch
|
||||
|
||||
# Required schemas have been backported
|
||||
Patch: 0001-build-Lower-gsettings-desktop-schemas-requirement.patch
|
||||
|
||||
# Revert gnome-session related changes
|
||||
Patch: 0001-Revert-data-Drop-org.gnome.Shell.desktop.patch
|
||||
Patch: 0002-Reapply-main-Notify-gnome-session-when-we-re-ready.patch
|
||||
|
||||
# GDM/Lock stuff
|
||||
Patch: 0001-screenShield-unblank-when-inserting-smartcard.patch
|
||||
Patch: enforce-smartcard-at-unlock.patch
|
||||
Patch: disable-unlock-entry-until-question.patch
|
||||
Patch: gdm-support-banner-message-file.patch
|
||||
Patch: 0001-systemActions-Optionally-allow-restart-shutdown-on-l.patch
|
||||
Patch: 0001-main-Register-session-with-GDM-on-startup.patch
|
||||
# Passwordless work
|
||||
# https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3212
|
||||
Patch: 0001-Support-for-web-login-and-unified-auth-mechanism.patch
|
||||
# Some users might have a broken PAM config, so we really need this
|
||||
# downstream patch to stop trying on configuration errors.
|
||||
Patch: 0001-gdm-Work-around-failing-fingerprint-auth.patch
|
||||
|
||||
# Extensions
|
||||
Patch: 0001-extensionDownloader-Refuse-to-override-system-extens.patch
|
||||
@ -56,6 +67,9 @@ Patch: 0001-st-texture-cache-purge-on-resume.patch
|
||||
Patch: fix-some-js-warnings.patch
|
||||
Patch: 0001-data-Update-generated-stylesheets.patch
|
||||
Patch: 0001-theme-Welcome-Illustration.patch
|
||||
Patch: screenshot-tool.patch
|
||||
Patch: 0001-Revert-status-keyboard-Limit-the-input-method-indica.patch
|
||||
Patch: 0001-Revert-Require-gjs-1.81.2-for-build-because-Intl.Seg.patch
|
||||
|
||||
%define eds_version 3.45.1
|
||||
%define gnome_desktop_version 44.0-7
|
||||
@ -64,16 +78,16 @@ Patch: 0001-theme-Welcome-Illustration.patch
|
||||
%define gjs_version 1.73.1
|
||||
%define gtk4_version 4.0.0
|
||||
%define adwaita_version 1.5.0
|
||||
%define mutter_version 47.0
|
||||
%define mutter_version 49.0
|
||||
%define polkit_version 0.100
|
||||
%define gsettings_desktop_schemas_version 47~alpha
|
||||
%define ibus_version 1.5.2
|
||||
%define gnome_bluetooth_version 1:42.3
|
||||
%define gstreamer_version 1.4.5
|
||||
%define pipewire_version 0.3.0
|
||||
%define pipewire_version 0.3.49
|
||||
%define gnome_settings_daemon_version 3.37.1
|
||||
|
||||
BuildRequires: bash-completion
|
||||
BuildRequires: pkgconfig(bash-completion)
|
||||
BuildRequires: gcc
|
||||
BuildRequires: meson
|
||||
BuildRequires: git
|
||||
@ -97,6 +111,7 @@ BuildRequires: pkgconfig(libpipewire-0.3) >= %{pipewire_version}
|
||||
BuildRequires: pkgconfig(gtk4) >= %{gtk4_version}
|
||||
BuildRequires: gettext >= 0.19.6
|
||||
BuildRequires: python3
|
||||
BuildRequires: python3-argcomplete
|
||||
|
||||
# for rst2man
|
||||
BuildRequires: python3-docutils
|
||||
@ -110,11 +125,9 @@ BuildRequires: pkgconfig(libpulse)
|
||||
BuildRequires: gnome-bluetooth-libs-devel >= %{gnome_bluetooth_version}
|
||||
%endif
|
||||
# Bootstrap requirements
|
||||
BuildRequires: gtk-doc
|
||||
%ifnarch s390 s390x
|
||||
Recommends: gnome-bluetooth%{?_isa} >= %{gnome_bluetooth_version}
|
||||
%endif
|
||||
Requires: gnome-desktop3%{?_isa} >= %{gnome_desktop_version}
|
||||
%if 0%{?rhel} != 7
|
||||
# Disabled on RHEL 7 to allow logging into KDE session by default
|
||||
Recommends: gnome-session-xsession
|
||||
@ -142,7 +155,9 @@ Requires: xdg-user-dirs-gtk
|
||||
# needed for schemas
|
||||
Requires: at-spi2-atk%{?_isa}
|
||||
# needed for on-screen keyboard
|
||||
Requires: ibus%{?_isa} >= %{ibus_version}
|
||||
Recommends: ibus%{?_isa} >= %{ibus_version}
|
||||
# needed for gobject-introspection typelib
|
||||
Requires: ibus-libs%{?_isa} >= %{ibus_version}
|
||||
# needed for "show keyboard layout"
|
||||
Requires: tecla
|
||||
# needed for the user menu
|
||||
@ -152,6 +167,7 @@ Requires: gdm-libs%{?_isa}
|
||||
Requires: gnome-control-center
|
||||
# needed by some utilities
|
||||
Requires: python3%{_isa}
|
||||
Requires: python3-argcomplete
|
||||
# needed for the dual-GPU launch menu
|
||||
Requires: switcheroo-control
|
||||
# needed for clocks/weather integration
|
||||
@ -178,6 +194,7 @@ Requires: webkitgtk6.0%{?_isa}
|
||||
ExcludeArch: %{ix86}
|
||||
%endif
|
||||
|
||||
Provides: gnome-shell(api) = %{major_version}
|
||||
Provides: desktop-notification-daemon = %{version}-%{release}
|
||||
Provides: PolicyKit-authentication-agent = %{version}-%{release}
|
||||
Provides: bundled(gvc)
|
||||
@ -241,6 +258,7 @@ desktop-file-validate %{buildroot}%{_datadir}/applications/org.gnome.Shell.Porta
|
||||
%doc NEWS README.md
|
||||
%{_bindir}/gnome-shell
|
||||
%{_bindir}/gnome-extensions
|
||||
%{_bindir}/gnome-screenshot-tool
|
||||
%{_bindir}/gnome-shell-extension-tool
|
||||
%{_bindir}/gnome-shell-test-tool
|
||||
%{_datadir}/glib-2.0/schemas/*.xml
|
||||
@ -248,6 +266,7 @@ desktop-file-validate %{buildroot}%{_datadir}/applications/org.gnome.Shell.Porta
|
||||
%{_datadir}/applications/org.gnome.Shell.Extensions.desktop
|
||||
%{_datadir}/applications/org.gnome.Shell.desktop
|
||||
%{_datadir}/bash-completion/completions/gnome-extensions
|
||||
%{_datadir}/bash-completion/completions/gnome-screenshot-tool
|
||||
%{_datadir}/gnome-control-center/keybindings/50-gnome-shell-launchers.xml
|
||||
%{_datadir}/gnome-control-center/keybindings/50-gnome-shell-screenshots.xml
|
||||
%{_datadir}/gnome-control-center/keybindings/50-gnome-shell-system.xml
|
||||
@ -258,13 +277,17 @@ desktop-file-validate %{buildroot}%{_datadir}/applications/org.gnome.Shell.Porta
|
||||
%{_datadir}/dbus-1/services/org.gnome.Shell.HotplugSniffer.service
|
||||
%{_datadir}/dbus-1/services/org.gnome.Shell.Notifications.service
|
||||
%{_datadir}/dbus-1/services/org.gnome.Shell.Screencast.service
|
||||
%{_datadir}/dbus-1/interfaces/org.gnome.Shell.Brightness.xml
|
||||
%{_datadir}/dbus-1/interfaces/org.gnome.Shell.Extensions.xml
|
||||
%{_datadir}/dbus-1/interfaces/org.gnome.Shell.Introspect.xml
|
||||
%{_datadir}/dbus-1/interfaces/org.gnome.Shell.PadOsd.xml
|
||||
%{_datadir}/dbus-1/interfaces/org.gnome.Shell.Screencast.xml
|
||||
%{_datadir}/dbus-1/interfaces/org.gnome.Shell.Screenshot.xml
|
||||
%{_datadir}/dbus-1/interfaces/org.gnome.Shell.ScreenTime.xml
|
||||
%{_datadir}/dbus-1/interfaces/org.gnome.ShellSearchProvider.xml
|
||||
%{_datadir}/dbus-1/interfaces/org.gnome.ShellSearchProvider2.xml
|
||||
%{_datadir}/desktop-directories/X-GNOME-Shell-System.directory
|
||||
%{_datadir}/desktop-directories/X-GNOME-Shell-Utilities.directory
|
||||
%{_datadir}/icons/hicolor/scalable/apps/org.gnome.Shell.Extensions.svg
|
||||
%{_datadir}/icons/hicolor/symbolic/apps/org.gnome.Shell.Extensions-symbolic.svg
|
||||
%{_userunitdir}/org.gnome.Shell-disable-extensions.service
|
||||
@ -276,6 +299,7 @@ desktop-file-validate %{buildroot}%{_datadir}/applications/org.gnome.Shell.Porta
|
||||
%{_libexecdir}/gnome-shell-perf-helper
|
||||
%{_libexecdir}/gnome-shell-hotplug-sniffer
|
||||
%{_mandir}/man1/gnome-extensions.1*
|
||||
%{_mandir}/man1/gnome-screenshot-tool.1*
|
||||
%{_mandir}/man1/gnome-shell.1*
|
||||
|
||||
%if %{portal_helper}
|
||||
@ -288,9 +312,76 @@ desktop-file-validate %{buildroot}%{_datadir}/applications/org.gnome.Shell.Porta
|
||||
|
||||
%changelog
|
||||
## START: Generated by rpmautospec
|
||||
* Wed Sep 24 2025 Darren Archibald <darren.archibald@oracle.com> - 47.4-3
|
||||
* Tue Feb 17 2026 Joan Torres Lopez <joantolo@redhat.com> - 49.4-2
|
||||
- Update passwordless GDM implementation to match upstream
|
||||
|
||||
* Wed Feb 11 2026 Florian Müllner <fmuellner@redhat.com> - 49.4-1
|
||||
- Update to 49.4
|
||||
|
||||
* Thu Jan 29 2026 Joan Torres Lopez <joantolo@redhat.com> - 49.1-9
|
||||
- Extend display time of messages interval
|
||||
|
||||
* Wed Jan 21 2026 Joan Torres Lopez <joantolo@redhat.com> - 49.1-8
|
||||
- Allow preemptive answer for 3 secs before locking text entry
|
||||
|
||||
* Wed Jan 21 2026 Joan Torres Lopez <joantolo@redhat.com> - 49.1-7
|
||||
- Update passwordless GDM patch series
|
||||
|
||||
* Thu Jan 15 2026 Joan Torres Lopez <joantolo@redhat.com> - 49.1-6
|
||||
- Update styles for passwordless GDM
|
||||
|
||||
* Thu Jan 15 2026 Joan Torres Lopez <joantolo@redhat.com> - 49.1-5
|
||||
- Add passwordless gdm patch series
|
||||
|
||||
* Fri Nov 14 2025 Joan Torres Lopez <joantolo@redhat.com> - 49.1-4
|
||||
- Register session with GDM on startup
|
||||
|
||||
* Thu Nov 13 2025 Florian Müllner <fmuellner@redhat.com> - 49.1-3
|
||||
- Provide gnome-shell(api) that extension packages can use to check
|
||||
compatibility
|
||||
|
||||
* Thu Nov 13 2025 Florian Müllner <fmuellner@redhat.com> - 49.1-2
|
||||
- Revert gnome-session related changes
|
||||
|
||||
* Tue Nov 11 2025 Florian Müllner <fmuellner@redhat.com> - 49.1-1
|
||||
- Update to 49.1
|
||||
|
||||
* Wed Oct 15 2025 Florian Müllner <fmuellner@redhat.com> - 47.10-1
|
||||
- Update to 47.10
|
||||
|
||||
* Wed Oct 15 2025 Florian Müllner <fmuellner@redhat.com> - 47.9-2
|
||||
- Remove unused gnome-desktop-3 require
|
||||
|
||||
* Wed Aug 27 2025 Florian Müllner <fmuellner@redhat.com> - 47.9-1
|
||||
- Update to 47.9
|
||||
|
||||
* Wed Aug 13 2025 Florian Müllner <fmuellner@redhat.com> - 47.8-6
|
||||
- Add missing require
|
||||
|
||||
* Wed Aug 13 2025 Florian Müllner <fmuellner@redhat.com> - 47.8-5
|
||||
- Revert basing input method indicator length on graphemes
|
||||
|
||||
* Thu Jul 31 2025 Joan Torres Lopez <joantolo@redhat.com> - 47.8-4
|
||||
- Allow restart/shutdown on lock screen
|
||||
|
||||
* Tue Jul 22 2025 Florian Müllner <fmuellner@redhat.com> - 47.8-3
|
||||
- Bump release to force rebuild
|
||||
|
||||
* Tue Jul 22 2025 Florian Müllner <fmuellner@redhat.com> - 47.8-2
|
||||
- Add screenshot CLI tool
|
||||
|
||||
* Tue Jul 15 2025 Florian Müllner <fmuellner@redhat.com> - 47.8-1
|
||||
- Update to 47.8
|
||||
|
||||
* Mon Jun 02 2025 Florian Müllner <fmuellner@redhat.com> - 47.7-1
|
||||
- Update to 47.7
|
||||
|
||||
* Wed May 21 2025 Florian Müllner <fmuellner@redhat.com> - 47.6-1
|
||||
- Update to 47.6
|
||||
|
||||
* Mon May 05 2025 Florian Müllner <fmuellner@redhat.com> - 47.5-1
|
||||
- Update to 47.5
|
||||
|
||||
* Fri Feb 14 2025 Florian Müllner <fmuellner@redhat.com> - 47.4-2
|
||||
- data: Tweak app defaults
|
||||
|
||||
|
||||
199
revert-gir-2.0-port.patch
Normal file
199
revert-gir-2.0-port.patch
Normal file
@ -0,0 +1,199 @@
|
||||
From 445bf69e9aafa8ad76e0b4bc70cd56359f717776 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Thu, 6 Nov 2025 15:20:15 +0100
|
||||
Subject: [PATCH 1/3] Revert "build: Depend on GLib 2.86.0"
|
||||
|
||||
This reverts commit 02d9487c1992972a344cac5866f0aedd357827ee.
|
||||
---
|
||||
meson.build | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/meson.build b/meson.build
|
||||
index 0cc6cceb94..ff5fc88734 100644
|
||||
--- a/meson.build
|
||||
+++ b/meson.build
|
||||
@@ -21,7 +21,7 @@ libmutter_test_pc = 'libmutter-test-' + mutter_api_version
|
||||
ecal_req = '>= 3.33.1'
|
||||
eds_req = '>= 3.33.1'
|
||||
gcr_req = '>= 3.90.0'
|
||||
-gio_req = '>= 2.86.0'
|
||||
+gio_req = '>= 2.85.1'
|
||||
gjs_req = '>= 1.85.90'
|
||||
gtk_req = '>= 4.0'
|
||||
mutter_req = '>= 49.0'
|
||||
--
|
||||
2.51.1
|
||||
|
||||
|
||||
From f4a4ce8a0608d8fb8c39cf7b81c828a22e305e63 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Thu, 6 Nov 2025 15:21:29 +0100
|
||||
Subject: [PATCH 2/3] Revert "build: Depend on gjs 1.85.90"
|
||||
|
||||
This reverts commit 08563fae7cd392527b0712c583750add21ac97d7.
|
||||
---
|
||||
meson.build | 2 +-
|
||||
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||
|
||||
diff --git a/meson.build b/meson.build
|
||||
index ff5fc88734..5bc23778ef 100644
|
||||
--- a/meson.build
|
||||
+++ b/meson.build
|
||||
@@ -22,7 +22,7 @@ ecal_req = '>= 3.33.1'
|
||||
eds_req = '>= 3.33.1'
|
||||
gcr_req = '>= 3.90.0'
|
||||
gio_req = '>= 2.85.1'
|
||||
-gjs_req = '>= 1.85.90'
|
||||
+gjs_req = '>= 1.85.1'
|
||||
gtk_req = '>= 4.0'
|
||||
mutter_req = '>= 49.0'
|
||||
polkit_req = '>= 0.100'
|
||||
--
|
||||
2.51.1
|
||||
|
||||
|
||||
From 6f94c04657a9013dd9ca2e5366e6118d8cb96b20 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Thu, 6 Nov 2025 15:27:19 +0100
|
||||
Subject: [PATCH 3/3] Revert "Port to gjs-1.85/girepository-2.0"
|
||||
|
||||
This reverts commit c8e28918aa96c53333ea7019eb24642b7878b548.
|
||||
---
|
||||
meson.build | 7 ++++---
|
||||
src/main.c | 23 ++++++++++-------------
|
||||
src/run-js-test.c | 9 +++------
|
||||
3 files changed, 17 insertions(+), 22 deletions(-)
|
||||
|
||||
diff --git a/meson.build b/meson.build
|
||||
index 5bc23778ef..ddd7d2c6e4 100644
|
||||
--- a/meson.build
|
||||
+++ b/meson.build
|
||||
@@ -21,8 +21,9 @@ libmutter_test_pc = 'libmutter-test-' + mutter_api_version
|
||||
ecal_req = '>= 3.33.1'
|
||||
eds_req = '>= 3.33.1'
|
||||
gcr_req = '>= 3.90.0'
|
||||
-gio_req = '>= 2.85.1'
|
||||
-gjs_req = '>= 1.85.1'
|
||||
+gio_req = '>= 2.79.2'
|
||||
+gi_req = '>= 1.49.1'
|
||||
+gjs_req = '>= 1.81.2'
|
||||
gtk_req = '>= 4.0'
|
||||
mutter_req = '>= 49.0'
|
||||
polkit_req = '>= 0.100'
|
||||
@@ -72,7 +73,7 @@ ecal_dep = dependency('libecal-2.0', version: ecal_req)
|
||||
eds_dep = dependency('libedataserver-1.2', version: eds_req)
|
||||
gcr_dep = dependency('gcr-4', version: gcr_req)
|
||||
gdk_pixbuf_dep = dependency('gdk-pixbuf-2.0')
|
||||
-gi_dep = dependency('girepository-2.0', version: gio_req)
|
||||
+gi_dep = dependency('gobject-introspection-1.0', version: gi_req)
|
||||
gio_dep = dependency('gio-2.0', version: gio_req)
|
||||
gio_unix_dep = dependency('gio-unix-2.0', version: gio_req)
|
||||
gjs_dep = dependency('gjs-1.0', version: gjs_req)
|
||||
diff --git a/src/main.c b/src/main.c
|
||||
index 99eca3e3c9..af4fa8597e 100644
|
||||
--- a/src/main.c
|
||||
+++ b/src/main.c
|
||||
@@ -13,7 +13,7 @@
|
||||
#include <clutter/clutter.h>
|
||||
#include <glib-unix.h>
|
||||
#include <glib/gi18n-lib.h>
|
||||
-#include <girepository/girepository.h>
|
||||
+#include <girepository.h>
|
||||
#include <meta/meta-context.h>
|
||||
#include <meta/meta-plugin.h>
|
||||
#include <meta/prefs.h>
|
||||
@@ -133,7 +133,7 @@ shell_dbus_init (gboolean replace)
|
||||
|
||||
#ifdef HAVE_EXE_INTROSPECTION
|
||||
static void
|
||||
-maybe_add_rpath_introspection_paths (GIRepository *repo)
|
||||
+maybe_add_rpath_introspection_paths (void)
|
||||
{
|
||||
ElfW (Dyn) *dyn;
|
||||
ElfW (Dyn) *rpath = NULL;
|
||||
@@ -210,8 +210,8 @@ maybe_add_rpath_introspection_paths (GIRepository *repo)
|
||||
g_debug ("Prepending RPATH directory '%s' "
|
||||
"to introsepciton library search path",
|
||||
rpath_dir->str);
|
||||
- gi_repository_prepend_search_path (repo, rpath_dir->str);
|
||||
- gi_repository_prepend_library_path (repo, rpath_dir->str);
|
||||
+ g_irepository_prepend_search_path (rpath_dir->str);
|
||||
+ g_irepository_prepend_library_path (rpath_dir->str);
|
||||
}
|
||||
}
|
||||
#endif /* HAVE_EXE_INTROSPECTION */
|
||||
@@ -219,23 +219,20 @@ maybe_add_rpath_introspection_paths (GIRepository *repo)
|
||||
static void
|
||||
shell_introspection_init (void)
|
||||
{
|
||||
- g_autoptr (GIRepository) repo = NULL;
|
||||
|
||||
- repo = gi_repository_dup_default ();
|
||||
-
|
||||
- gi_repository_prepend_search_path (repo, MUTTER_TYPELIB_DIR);
|
||||
- gi_repository_prepend_search_path (repo, SHELL_TYPELIB_DIR);
|
||||
+ g_irepository_prepend_search_path (MUTTER_TYPELIB_DIR);
|
||||
+ g_irepository_prepend_search_path (SHELL_TYPELIB_DIR);
|
||||
|
||||
/* We need to explicitly add the directories where the private libraries are
|
||||
* installed to the GIR's library path, so that they can be found at runtime
|
||||
* when linking using DT_RUNPATH (instead of DT_RPATH), which is the default
|
||||
* for some linkers (e.g. gold) and in some distros (e.g. Debian).
|
||||
*/
|
||||
- gi_repository_prepend_library_path (repo, MUTTER_TYPELIB_DIR);
|
||||
- gi_repository_prepend_library_path (repo, GNOME_SHELL_PKGLIBDIR);
|
||||
+ g_irepository_prepend_library_path (MUTTER_TYPELIB_DIR);
|
||||
+ g_irepository_prepend_library_path (GNOME_SHELL_PKGLIBDIR);
|
||||
|
||||
#ifdef HAVE_EXE_INTROSPECTION
|
||||
- maybe_add_rpath_introspection_paths (repo);
|
||||
+ maybe_add_rpath_introspection_paths ();
|
||||
#endif
|
||||
}
|
||||
|
||||
@@ -614,7 +611,7 @@ main (int argc, char **argv)
|
||||
context = meta_create_context (WM_NAME);
|
||||
meta_context_add_option_entries (context, gnome_shell_options,
|
||||
GETTEXT_PACKAGE);
|
||||
- meta_context_add_option_group (context, gi_repository_get_option_group ());
|
||||
+ meta_context_add_option_group (context, g_irepository_get_option_group ());
|
||||
|
||||
session_mode = (char *) g_getenv ("GNOME_SHELL_SESSION_MODE");
|
||||
|
||||
diff --git a/src/run-js-test.c b/src/run-js-test.c
|
||||
index 7a539d3a23..4f795252c2 100644
|
||||
--- a/src/run-js-test.c
|
||||
+++ b/src/run-js-test.c
|
||||
@@ -30,7 +30,7 @@
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
-#include <girepository/girepository.h>
|
||||
+#include <girepository.h>
|
||||
#include <gjs/gjs.h>
|
||||
|
||||
#include "shell-global.h"
|
||||
@@ -64,7 +64,6 @@ int
|
||||
main (int argc, char **argv)
|
||||
{
|
||||
GOptionContext *context;
|
||||
- g_autoptr (GIRepository) repo = NULL;
|
||||
g_autoptr (GError) error = NULL;
|
||||
ShellGlobal *global;
|
||||
GjsContext *js_context;
|
||||
@@ -86,10 +85,8 @@ main (int argc, char **argv)
|
||||
global = shell_global_get ();
|
||||
js_context = _shell_global_get_gjs_context (global);
|
||||
|
||||
- repo = gi_repository_dup_default ();
|
||||
-
|
||||
- gi_repository_prepend_search_path (repo, MUTTER_TYPELIB_DIR);
|
||||
- gi_repository_prepend_search_path (repo, SHELL_TYPELIB_DIR);
|
||||
+ g_irepository_prepend_search_path (MUTTER_TYPELIB_DIR);
|
||||
+ g_irepository_prepend_search_path (SHELL_TYPELIB_DIR);
|
||||
|
||||
if (argc < 2)
|
||||
{
|
||||
--
|
||||
2.51.1
|
||||
|
||||
453
screenshot-tool.patch
Normal file
453
screenshot-tool.patch
Normal file
@ -0,0 +1,453 @@
|
||||
From 83a585f075bacf766e4cf40429fc41c217cf2e29 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Thu, 6 Nov 2025 15:17:41 +0100
|
||||
Subject: [PATCH 1/2] Revert "screenshot: Remove gnome-screenshot from allowed
|
||||
senders"
|
||||
|
||||
The following commit will add a CLI screenshot tool that reuses
|
||||
the D-Bus name from gnome-screenshot, so re-allow the caller.
|
||||
|
||||
This reverts commit c9944dbf9bd47a972eb4f3908fefe5878d315d6e.
|
||||
---
|
||||
js/ui/screenshot.js | 1 +
|
||||
1 file changed, 1 insertion(+)
|
||||
|
||||
diff --git a/js/ui/screenshot.js b/js/ui/screenshot.js
|
||||
index 209207710b..328080235c 100644
|
||||
--- a/js/ui/screenshot.js
|
||||
+++ b/js/ui/screenshot.js
|
||||
@@ -2450,6 +2450,7 @@ export class ScreenshotService {
|
||||
this._senderChecker = new DBusSenderChecker([
|
||||
'org.gnome.SettingsDaemon.MediaKeys',
|
||||
'org.freedesktop.impl.portal.desktop.gnome',
|
||||
+ 'org.gnome.Screenshot',
|
||||
]);
|
||||
|
||||
this._lockdownSettings = new Gio.Settings({schema_id: 'org.gnome.desktop.lockdown'});
|
||||
--
|
||||
2.51.1
|
||||
|
||||
|
||||
From 525260b46f147fd5272e9c5047a8263f4db1634f Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Fri, 18 Jul 2025 21:34:36 +0200
|
||||
Subject: [PATCH 2/2] Add screenshot CLI tool
|
||||
|
||||
The tool provides the same API as gnome-screenshot, but leverages
|
||||
GNOME's built-in screenshot UI instead of implementing its own
|
||||
interactive dialog.
|
||||
---
|
||||
man/gnome-screenshot-tool.rst | 49 +++++++
|
||||
man/meson.build | 23 ++-
|
||||
meson.build | 2 +
|
||||
src/gnome-screenshot-tool | 266 ++++++++++++++++++++++++++++++++++
|
||||
src/meson.build | 26 ++++
|
||||
5 files changed, 358 insertions(+), 8 deletions(-)
|
||||
create mode 100644 man/gnome-screenshot-tool.rst
|
||||
create mode 100755 src/gnome-screenshot-tool
|
||||
|
||||
diff --git a/man/gnome-screenshot-tool.rst b/man/gnome-screenshot-tool.rst
|
||||
new file mode 100644
|
||||
index 0000000000..a471738394
|
||||
--- /dev/null
|
||||
+++ b/man/gnome-screenshot-tool.rst
|
||||
@@ -0,0 +1,49 @@
|
||||
+=====================
|
||||
+gnome-screenshot-tool
|
||||
+=====================
|
||||
+
|
||||
+-----------------------------------------
|
||||
+Screenshot CLI tool for the GNOME desktop
|
||||
+-----------------------------------------
|
||||
+
|
||||
+:Manual section: 1
|
||||
+:Manual group: User Commands
|
||||
+
|
||||
+SYNOPSIS
|
||||
+--------
|
||||
+**gnome-screenshot-tool** [*OPTION*...]
|
||||
+
|
||||
+DESCRIPTION
|
||||
+-----------
|
||||
+**gnome-screenshot-tool** is a GNOME utility for taking screenshots of
|
||||
+the entire screen, a window or a user-defined area of the screen.
|
||||
+
|
||||
+OPTIONS
|
||||
+-------
|
||||
+``-w``, ``--window``
|
||||
+
|
||||
+ Grab the currently active window instead of the entire screen
|
||||
+
|
||||
+``-a``, ``--area``
|
||||
+
|
||||
+ Grab an area of the screen instead of the entire screen
|
||||
+
|
||||
+``-i``, ``--interactive``
|
||||
+
|
||||
+ Bring up GNOME's native screenshot dialog
|
||||
+
|
||||
+``-p``, ``--include-pointer``
|
||||
+
|
||||
+ Include the pointer with the screenshot
|
||||
+
|
||||
+``-d``, ``--delay``\ =\ *SECONDS*
|
||||
+
|
||||
+ Take the screenshot after the specified delay [in seconds]
|
||||
+
|
||||
+``-f``, ``--file``\ =\ *FILENAME*
|
||||
+
|
||||
+ Save the screenshot directly to this file
|
||||
+
|
||||
+``-h``, ``--help``
|
||||
+
|
||||
+ Show a summary of the available options
|
||||
diff --git a/man/meson.build b/man/meson.build
|
||||
index c61bf51513..cfb9c8e07f 100644
|
||||
--- a/man/meson.build
|
||||
+++ b/man/meson.build
|
||||
@@ -1,8 +1,15 @@
|
||||
-custom_target('man page',
|
||||
- input: 'gnome-shell.rst',
|
||||
- output: 'gnome-shell.1',
|
||||
- command: [rst2man, '--syntax-highlight=none', '@INPUT@'],
|
||||
- capture: true,
|
||||
- install_dir: mandir + '/man1',
|
||||
- install: true
|
||||
-)
|
||||
+man_pages = [
|
||||
+ 'gnome-shell.rst',
|
||||
+ 'gnome-screenshot-tool.rst',
|
||||
+]
|
||||
+
|
||||
+foreach page : man_pages
|
||||
+ custom_target(f'@page@ man page',
|
||||
+ input: page,
|
||||
+ output: '@BASENAME@.1',
|
||||
+ command: [rst2man, '--syntax-highlight=none', '@INPUT@'],
|
||||
+ capture: true,
|
||||
+ install_dir: mandir + '/man1',
|
||||
+ install: true
|
||||
+ )
|
||||
+endforeach
|
||||
diff --git a/meson.build b/meson.build
|
||||
index ddd7d2c6e4..327e5f0b7e 100644
|
||||
--- a/meson.build
|
||||
+++ b/meson.build
|
||||
@@ -141,6 +141,8 @@ if get_option('man')
|
||||
subdir('man')
|
||||
endif
|
||||
|
||||
+bash_completion = dependency('bash-completion', required: false)
|
||||
+
|
||||
mutter_typelibdir = mutter_dep.get_variable('typelibdir')
|
||||
python = find_program('python3')
|
||||
gjs = find_program('gjs')
|
||||
diff --git a/src/gnome-screenshot-tool b/src/gnome-screenshot-tool
|
||||
new file mode 100755
|
||||
index 0000000000..e29650abfe
|
||||
--- /dev/null
|
||||
+++ b/src/gnome-screenshot-tool
|
||||
@@ -0,0 +1,266 @@
|
||||
+#!/usr/bin/env python3
|
||||
+
|
||||
+import argparse
|
||||
+import os
|
||||
+import gi
|
||||
+
|
||||
+gi.require_version('Gdk', '4.0')
|
||||
+gi.require_version('Gtk', '4.0')
|
||||
+gi.require_version('GdkPixbuf', '2.0')
|
||||
+from gi.repository import GLib, Gio, GdkPixbuf, Gdk, Gtk # type: ignore
|
||||
+
|
||||
+try:
|
||||
+ import argcomplete
|
||||
+except ModuleNotFoundError:
|
||||
+ pass
|
||||
+
|
||||
+NAME = "org.gnome.Shell.Screenshot"
|
||||
+OBJECT_PATH = "/org/gnome/Shell/Screenshot"
|
||||
+INTERFACE = "org.gnome.Shell.Screenshot"
|
||||
+
|
||||
+class Screenshot:
|
||||
+ def __init__(self):
|
||||
+ self._proxy = Gio.DBusProxy.new_for_bus_sync(
|
||||
+ bus_type = Gio.BusType.SESSION,
|
||||
+ flags = Gio.DBusProxyFlags.NONE,
|
||||
+ info = None,
|
||||
+ name = NAME,
|
||||
+ object_path = OBJECT_PATH,
|
||||
+ interface_name = INTERFACE,
|
||||
+ cancellable = None,
|
||||
+ )
|
||||
+
|
||||
+ def screenshot(self, include_cursor) -> GdkPixbuf.Pixbuf:
|
||||
+ variant = self._proxy.call_sync(
|
||||
+ method_name = "Screenshot",
|
||||
+ parameters = GLib.Variant(
|
||||
+ "(bbs)",
|
||||
+ (
|
||||
+ include_cursor,
|
||||
+ True,
|
||||
+ self._get_tmp_filename(),
|
||||
+ ),
|
||||
+ ),
|
||||
+ flags = Gio.DBusCallFlags.NO_AUTO_START,
|
||||
+ timeout_msec = -1,
|
||||
+ cancellable = None,
|
||||
+ )
|
||||
+ return self._get_screenshot_from_result(variant)
|
||||
+
|
||||
+ def screenshot_window(self, include_cursor) -> GdkPixbuf.Pixbuf:
|
||||
+ variant = self._proxy.call_sync(
|
||||
+ method_name = "ScreenshotWindow",
|
||||
+ parameters = GLib.Variant(
|
||||
+ "(bbbs)",
|
||||
+ (
|
||||
+ True,
|
||||
+ include_cursor,
|
||||
+ True,
|
||||
+ self._get_tmp_filename(),
|
||||
+ ),
|
||||
+ ),
|
||||
+ flags = Gio.DBusCallFlags.NO_AUTO_START,
|
||||
+ timeout_msec = -1,
|
||||
+ cancellable = None,
|
||||
+ )
|
||||
+ return self._get_screenshot_from_result(variant)
|
||||
+
|
||||
+ def screenshot_area(self, x, y, width, height) -> GdkPixbuf.Pixbuf:
|
||||
+ variant = self._proxy.call_sync(
|
||||
+ method_name = "ScreenshotArea",
|
||||
+ parameters = GLib.Variant(
|
||||
+ "(iiiibs)",
|
||||
+ (
|
||||
+ x,
|
||||
+ y,
|
||||
+ width,
|
||||
+ height,
|
||||
+ True,
|
||||
+ self._get_tmp_filename(),
|
||||
+ ),
|
||||
+ ),
|
||||
+ flags = Gio.DBusCallFlags.NO_AUTO_START,
|
||||
+ timeout_msec = -1,
|
||||
+ cancellable = None,
|
||||
+ )
|
||||
+ return self._get_screenshot_from_result(variant)
|
||||
+
|
||||
+ def interactive_screenshot(self) -> GdkPixbuf.Pixbuf:
|
||||
+ variant = self._proxy.call_sync(
|
||||
+ method_name = "InteractiveScreenshot",
|
||||
+ parameters = None,
|
||||
+ flags = Gio.DBusCallFlags.NO_AUTO_START,
|
||||
+ timeout_msec = GLib.MAXINT,
|
||||
+ cancellable = None,
|
||||
+ )
|
||||
+ [success, uri] = variant
|
||||
+ file = Gio.File.new_for_uri(uri)
|
||||
+ return self._get_screenshot_from_result((success, file.get_path()))
|
||||
+
|
||||
+ def select_area(self) -> tuple[int, int, int, int]:
|
||||
+ variant = self._proxy.call_sync(
|
||||
+ method_name = "SelectArea",
|
||||
+ parameters = None,
|
||||
+ flags = Gio.DBusCallFlags.NO_AUTO_START,
|
||||
+ timeout_msec = -1,
|
||||
+ cancellable = None,
|
||||
+ )
|
||||
+ [x, y, width, height] = variant
|
||||
+ return (x, y, width, height)
|
||||
+
|
||||
+ def _get_screenshot_from_result(self, variant):
|
||||
+ [success, filename] = variant
|
||||
+ assert success
|
||||
+ screenshot = GdkPixbuf.Pixbuf.new_from_file(filename)
|
||||
+ GLib.unlink(filename)
|
||||
+ return screenshot
|
||||
+
|
||||
+ def _get_tmp_filename(self):
|
||||
+ path = GLib.build_filenamev([
|
||||
+ GLib.get_user_cache_dir(),
|
||||
+ "gnome-screenshot-tool",
|
||||
+ ])
|
||||
+ GLib.mkdir_with_parents(path, 0o700)
|
||||
+ return GLib.build_filenamev([path, f'scr-{GLib.random_int()}'])
|
||||
+
|
||||
+class ScreenshotApp(Gtk.Application):
|
||||
+ def __init__(self, config):
|
||||
+ super().__init__(application_id="org.gnome.Screenshot")
|
||||
+
|
||||
+ self._config = config
|
||||
+
|
||||
+ def do_startup(self):
|
||||
+ Gtk.Application.do_startup(self)
|
||||
+ self._proxy = Screenshot()
|
||||
+
|
||||
+ def do_activate(self):
|
||||
+ self.hold()
|
||||
+ if self._config.area:
|
||||
+ self._selected_area = self._proxy.select_area()
|
||||
+ self._start_screenshot_timeout()
|
||||
+
|
||||
+ def _start_screenshot_timeout(self):
|
||||
+ GLib.timeout_add_seconds(self._config.delay, self._take_screenshot)
|
||||
+
|
||||
+ def _take_screenshot(self):
|
||||
+ include_pointer = self._config.include_pointer
|
||||
+
|
||||
+ try:
|
||||
+ if self._config.interactive:
|
||||
+ screenshot = self._proxy.interactive_screenshot()
|
||||
+ elif self._config.area:
|
||||
+ [x, y, width, height] = self._selected_area
|
||||
+ screenshot = self._proxy.screenshot_area(x, y, width, height)
|
||||
+ elif self._config.window:
|
||||
+ screenshot = self._proxy.screenshot_window(include_pointer)
|
||||
+ else:
|
||||
+ screenshot = self._proxy.screenshot(include_pointer)
|
||||
+
|
||||
+ # if self._config.clipboard:
|
||||
+ # self._save_screenshot_to_clipboard(screenshot)
|
||||
+
|
||||
+ if self._config.file:
|
||||
+ target_file = Gio.File.new_for_commandline_arg(self._config.file)
|
||||
+ override = True
|
||||
+ else:
|
||||
+ target_file = self._get_default_target_file()
|
||||
+ override = False
|
||||
+
|
||||
+ self._save_screenshot_to_file(screenshot, target_file, override)
|
||||
+ except Exception as e:
|
||||
+ print(f'Failed to take screenshot: {e}')
|
||||
+ finally:
|
||||
+ self.release()
|
||||
+
|
||||
+ return GLib.SOURCE_REMOVE
|
||||
+
|
||||
+ def _save_screenshot_to_clipboard(self, screenshot):
|
||||
+ dpy = Gdk.Display.get_default()
|
||||
+ clipboard = dpy.get_clipboard()
|
||||
+ clipboard.set(screenshot)
|
||||
+
|
||||
+ def _save_screenshot_to_file(self, screenshot, file, override):
|
||||
+ if override:
|
||||
+ ostream = file.replace(None, False, Gio.FileCreateFlags.NONE, None)
|
||||
+ else:
|
||||
+ ostream = file.create(Gio.FileCreateFlags.NONE, None)
|
||||
+
|
||||
+ [_, ext] = os.path.splitext(file.get_basename())
|
||||
+ if not ext:
|
||||
+ ext = 'png'
|
||||
+ else:
|
||||
+ ext = ext[1:]
|
||||
+
|
||||
+ def find_writable_format(formats, ext):
|
||||
+ for f in formats:
|
||||
+ for e in f.get_extensions():
|
||||
+ if e == ext and f.is_writable():
|
||||
+ return f.get_name()
|
||||
+ return None
|
||||
+
|
||||
+ formats = GdkPixbuf.Pixbuf.get_formats()
|
||||
+ format = find_writable_format(formats, ext)
|
||||
+
|
||||
+ if format == 'png':
|
||||
+ keys = ["tEXt::Software"]
|
||||
+ values = ["gnome-screenshot-tool"]
|
||||
+ else:
|
||||
+ keys = None
|
||||
+ values = None
|
||||
+
|
||||
+ screenshot.save_to_streamv(ostream, format, keys, values, None)
|
||||
+
|
||||
+ def _get_default_target_file(self):
|
||||
+ path = GLib.build_filenamev([
|
||||
+ GLib.get_user_special_dir(GLib.UserDirectory.DIRECTORY_PICTURES) or GLib.get_home_dir(),
|
||||
+ "Screenshots",
|
||||
+ ])
|
||||
+ dir = Gio.File.new_for_path(path)
|
||||
+ try:
|
||||
+ dir.make_directory_with_parents(None)
|
||||
+ except GLib.Error as e:
|
||||
+ if not e.matches(Gio.io_error_quark(), Gio.IOErrorEnum.EXISTS):
|
||||
+ raise e
|
||||
+
|
||||
+ timestamp = GLib.DateTime.new_now_local().format('%Y-%m-%d %H-%M-%S')
|
||||
+ name = "Screenshot From %s" % (timestamp)
|
||||
+
|
||||
+ def suffixes() -> str:
|
||||
+ yield ''
|
||||
+
|
||||
+ i = 1
|
||||
+ while True:
|
||||
+ yield f'-{i}'
|
||||
+ i = i + 1
|
||||
+
|
||||
+ for suffix in suffixes():
|
||||
+ file = dir.get_child(f'{name}{suffix}.png')
|
||||
+ if not file.query_exists(None):
|
||||
+ return file
|
||||
+
|
||||
+def main():
|
||||
+ parser = argparse.ArgumentParser()
|
||||
+
|
||||
+ group = parser.add_mutually_exclusive_group()
|
||||
+ group.add_argument("-w", "--window", action="store_true", help="Grab a window instead of the entire screen")
|
||||
+ group.add_argument("-a", "--area", action="store_true", help="Grab an area of the screen instead of the entire screen")
|
||||
+ group.add_argument("-i", "--interactive", action="store_true", help="Interactively set options")
|
||||
+
|
||||
+ # parser.add_argument("-c", "--clipboard", action="store_true", help="Send the grab directly to the clipboard")
|
||||
+ parser.add_argument("-p", "--include-pointer", action="store_true", help="Include the pointer with the screenshot")
|
||||
+ parser.add_argument("-d", "--delay", type=int, default=0, help="Take a screenshot after the specified delay (in seconds)")
|
||||
+ parser.add_argument("-f", "--file", type=str, help="Save screenshot directly to this file")
|
||||
+
|
||||
+ if argcomplete:
|
||||
+ argcomplete.autocomplete(parser)
|
||||
+ args = parser.parse_args()
|
||||
+
|
||||
+ if args.interactive:
|
||||
+ if args.include_pointer:
|
||||
+ print("Option --include-pointer is ignored in interactive mode.")
|
||||
+
|
||||
+ app = ScreenshotApp(args)
|
||||
+ app.run(None)
|
||||
+
|
||||
+if __name__ == "__main__":
|
||||
+ main()
|
||||
diff --git a/src/meson.build b/src/meson.build
|
||||
index a4ce889eac..d83d84a5e9 100644
|
||||
--- a/src/meson.build
|
||||
+++ b/src/meson.build
|
||||
@@ -315,3 +315,29 @@ run_test = executable('run-js-test', 'run-js-test.c',
|
||||
include_directories: [conf_inc],
|
||||
build_rpath: mutter_typelibdir,
|
||||
)
|
||||
+
|
||||
+install_data(
|
||||
+ 'gnome-screenshot-tool',
|
||||
+ install_dir: bindir
|
||||
+)
|
||||
+
|
||||
+if bash_completion.found()
|
||||
+ bash_completion_dir = bash_completion.get_variable(
|
||||
+ pkgconfig: 'completionsdir',
|
||||
+ pkgconfig_define: ['datadir', datadir],
|
||||
+ )
|
||||
+
|
||||
+ register_python_argcomplete = find_program('register-python-argcomplete')
|
||||
+
|
||||
+ custom_target(
|
||||
+ 'screenshot-tool-bash-completion',
|
||||
+ output: 'gnome-screenshot-tool',
|
||||
+ command: [
|
||||
+ register_python_argcomplete,
|
||||
+ 'gnome-screenshot-tool',
|
||||
+ ],
|
||||
+ capture: true,
|
||||
+ install_dir: bash_completion_dir,
|
||||
+ install: true,
|
||||
+ )
|
||||
+endif
|
||||
--
|
||||
2.51.1
|
||||
|
||||
2
sources
2
sources
@ -1 +1 @@
|
||||
SHA512 (gnome-shell-47.4.tar.xz) = 65a0dab1bdd6957e52c624fde21ff3fe1d189aa0d6e2a13035ab53ab51e82ff8a88d28a5308c77d4650d5e1b0f643be702ee767379c96a10308752924c79dd72
|
||||
f101a8f261f6e3ac9f2b08efad71fd6be85f3c7d9070c747e5b9420fa9faa9e86281f76774385807bd9b1ce100fc82b37fa646147e7a4003c7ce3f8cf66b5670 gnome-shell-49.4.tar.xz
|
||||
|
||||
@ -1,384 +0,0 @@
|
||||
From cfeade9501e158b426f571d05ab15ee6dbe49e75 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Fri, 7 Feb 2025 15:01:48 +0100
|
||||
Subject: [PATCH 1/3] data: Generate dash/app-grid defaults from text files
|
||||
|
||||
Defining default apps as serialized GVariants isn't very human-friendly,
|
||||
which likely contributes to the fact that the lists are in parts horribly
|
||||
outdated (Books! Cheese! Screenshot! gedit!).
|
||||
|
||||
Instead, generate the lists at build time from simple text files, which
|
||||
should be much easier to update.
|
||||
|
||||
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3632>
|
||||
---
|
||||
data/default-apps/app-grid.txt | 21 ++++++++++++++
|
||||
data/default-apps/dash.txt | 6 ++++
|
||||
data/default-apps/utilities-folder.txt | 17 +++++++++++
|
||||
data/meson.build | 8 ++++++
|
||||
data/org.gnome.shell.gschema.xml.in | 28 +++---------------
|
||||
js/misc/config.js.in | 2 ++
|
||||
js/misc/meson.build | 4 +++
|
||||
js/ui/appDisplay.js | 19 ++----------
|
||||
meson.build | 1 +
|
||||
meson/generate-app-list.py | 40 ++++++++++++++++++++++++++
|
||||
10 files changed, 106 insertions(+), 40 deletions(-)
|
||||
create mode 100644 data/default-apps/app-grid.txt
|
||||
create mode 100644 data/default-apps/dash.txt
|
||||
create mode 100644 data/default-apps/utilities-folder.txt
|
||||
create mode 100755 meson/generate-app-list.py
|
||||
|
||||
diff --git a/data/default-apps/app-grid.txt b/data/default-apps/app-grid.txt
|
||||
new file mode 100644
|
||||
index 0000000000..d78ed165eb
|
||||
--- /dev/null
|
||||
+++ b/data/default-apps/app-grid.txt
|
||||
@@ -0,0 +1,21 @@
|
||||
+org.gnome.Geary.desktop
|
||||
+org.gnome.Contacts.desktop
|
||||
+org.gnome.Weather.desktop
|
||||
+org.gnome.clocks.desktop
|
||||
+org.gnome.Maps.desktop
|
||||
+org.gnome.Books.desktop
|
||||
+org.gnome.Photos.desktop
|
||||
+org.gnome.Totem.desktop
|
||||
+org.gnome.Calculator.desktop
|
||||
+org.gnome.gedit.desktop
|
||||
+simple-scan.desktop
|
||||
+org.gnome.Settings.desktop
|
||||
+org.gnome.SystemMonitor.desktop
|
||||
+org.gnome.Boxes.desktop
|
||||
+org.gnome.Terminal.desktop
|
||||
+Utilities # folder
|
||||
+org.gnome.Characters.desktop
|
||||
+yelp.desktop
|
||||
+org.gnome.Screenshot.desktop
|
||||
+org.gnome.Cheese.desktop
|
||||
+org.gnome.font-viewer.desktop
|
||||
diff --git a/data/default-apps/dash.txt b/data/default-apps/dash.txt
|
||||
new file mode 100644
|
||||
index 0000000000..2a8e8bcd06
|
||||
--- /dev/null
|
||||
+++ b/data/default-apps/dash.txt
|
||||
@@ -0,0 +1,6 @@
|
||||
+org.gnome.Epiphany.desktop
|
||||
+org.gnome.Calendar.desktop
|
||||
+org.gnome.Music.desktop
|
||||
+gnome.Nautilus.desktop
|
||||
+org.gnome.Software.desktop
|
||||
+org.gnome.TextEditor.desktop
|
||||
diff --git a/data/default-apps/utilities-folder.txt b/data/default-apps/utilities-folder.txt
|
||||
new file mode 100644
|
||||
index 0000000000..6169977751
|
||||
--- /dev/null
|
||||
+++ b/data/default-apps/utilities-folder.txt
|
||||
@@ -0,0 +1,17 @@
|
||||
+# Sorted by name as shown in menus, not filename
|
||||
+nm-connection-editor.desktop # Advanced Network Configuration
|
||||
+org.gnome.DejaDup.desktop # Backups
|
||||
+org.gnome.Characters.desktop # Characters
|
||||
+org.gnome.Connections.desktop # Connections
|
||||
+org.gnome.DiskUtility.desktop # Disks
|
||||
+org.gnome.baobab.desktop # Disk Usage Analyzer
|
||||
+org.gnome.Evince.desktop # Document Viewer
|
||||
+org.gnome.FileRoller.desktop # File Roller
|
||||
+org.gnome.font-viewer.desktop # Fonts
|
||||
+org.gnome.Loupe.desktop # Image Viewer
|
||||
+org.gnome.Logs.desktop # Logs
|
||||
+org.freedesktop.MalcontentControl.desktop # Parental Controls
|
||||
+org.gnome.seahorse.Application.desktop # Passwords and Keys
|
||||
+org.freedesktop.GnomeAbrt.desktop # Problem Reporting
|
||||
+org.gnome.tweaks.desktop # Tweaks
|
||||
+org.gnome.Usage.desktop # Usage
|
||||
diff --git a/data/meson.build b/data/meson.build
|
||||
index ed13b6baea..c7565ee810 100644
|
||||
--- a/data/meson.build
|
||||
+++ b/data/meson.build
|
||||
@@ -90,6 +90,14 @@ install_data(keybinding_files, install_dir: keysdir)
|
||||
|
||||
schemaconf = configuration_data()
|
||||
schemaconf.set('GETTEXT_PACKAGE', meson.project_name())
|
||||
+schemaconf.set('DASH_APPS', run_command(
|
||||
+ generate_app_list, 'default-apps/dash.txt',
|
||||
+ check: true,
|
||||
+).stdout())
|
||||
+schemaconf.set('APP_GRID_APPS', run_command(
|
||||
+ generate_app_list, '--pages', 'default-apps/app-grid.txt',
|
||||
+ check: true,
|
||||
+).stdout())
|
||||
schema = configure_file(
|
||||
input: 'org.gnome.shell.gschema.xml.in',
|
||||
output: 'org.gnome.shell.gschema.xml',
|
||||
diff --git a/data/org.gnome.shell.gschema.xml.in b/data/org.gnome.shell.gschema.xml.in
|
||||
index 3cd37692a7..b1c2534f9c 100644
|
||||
--- a/data/org.gnome.shell.gschema.xml.in
|
||||
+++ b/data/org.gnome.shell.gschema.xml.in
|
||||
@@ -61,7 +61,9 @@
|
||||
</description>
|
||||
</key>
|
||||
<key name="favorite-apps" type="as">
|
||||
- <default>[ 'org.gnome.Epiphany.desktop', 'org.gnome.Calendar.desktop', 'org.gnome.Music.desktop', 'org.gnome.Nautilus.desktop', 'org.gnome.Software.desktop', 'org.gnome.TextEditor.desktop']</default>
|
||||
+ <default>
|
||||
+ @DASH_APPS@
|
||||
+ </default>
|
||||
<summary>List of desktop file IDs for favorite applications</summary>
|
||||
<description>
|
||||
The applications corresponding to these identifiers
|
||||
@@ -118,29 +120,7 @@
|
||||
</key>
|
||||
<key name="app-picker-layout" type="aa{sv}">
|
||||
<default><![CDATA[
|
||||
- [{
|
||||
- 'org.gnome.Geary.desktop': <{'position': <0>}>,
|
||||
- 'org.gnome.Contacts.desktop': <{'position': <1>}>,
|
||||
- 'org.gnome.Weather.desktop': <{'position': <2>}>,
|
||||
- 'org.gnome.clocks.desktop': <{'position': <3>}>,
|
||||
- 'org.gnome.Maps.desktop': <{'position': <4>}>,
|
||||
- 'org.gnome.Books.desktop': <{'position': <5>}>,
|
||||
- 'org.gnome.Photos.desktop': <{'position': <6>}>,
|
||||
- 'org.gnome.Totem.desktop': <{'position': <7>}>,
|
||||
- 'org.gnome.Calculator.desktop': <{'position': <8>}>,
|
||||
- 'org.gnome.gedit.desktop': <{'position': <9>}>,
|
||||
- 'simple-scan.desktop': <{'position': <10>}>,
|
||||
- 'org.gnome.Settings.desktop': <{'position': <11>}>,
|
||||
- 'org.gnome.SystemMonitor.desktop': <{'position': <12>}>,
|
||||
- 'org.gnome.Boxes.desktop': <{'position': <13>}>,
|
||||
- 'org.gnome.Terminal.desktop': <{'position': <14>}>,
|
||||
- 'Utilities': <{'position': <15>}>,
|
||||
- 'org.gnome.Characters.desktop': <{'position': <16>}>,
|
||||
- 'yelp.desktop': <{'position': <17>}>,
|
||||
- 'org.gnome.Screenshot.desktop': <{'position': <18>}>,
|
||||
- 'org.gnome.Cheese.desktop': <{'position': <19>}>,
|
||||
- 'org.gnome.font-viewer.desktop': <{'position': <20>}>
|
||||
- }]
|
||||
+ @APP_GRID_APPS@
|
||||
]]></default>
|
||||
<summary>Layout of the app picker</summary>
|
||||
<description>
|
||||
diff --git a/js/misc/config.js.in b/js/misc/config.js.in
|
||||
index a5069e438a..6485d614f5 100644
|
||||
--- a/js/misc/config.js.in
|
||||
+++ b/js/misc/config.js.in
|
||||
@@ -20,3 +20,5 @@ export const LIBMUTTER_API_VERSION = '@LIBMUTTER_API_VERSION@';
|
||||
|
||||
export const HAVE_BLUETOOTH = pkg.checkSymbol('GnomeBluetooth', '3.0',
|
||||
'Client.default_adapter_state');
|
||||
+
|
||||
+export const UTILITIES_FOLDER_APPS = @UTILS_FOLDER_APPS@;
|
||||
diff --git a/js/misc/meson.build b/js/misc/meson.build
|
||||
index 5fc8ca433f..4b137ef3e6 100644
|
||||
--- a/js/misc/meson.build
|
||||
+++ b/js/misc/meson.build
|
||||
@@ -5,6 +5,10 @@ jsconf.set('GETTEXT_PACKAGE', meson.project_name())
|
||||
jsconf.set('LIBMUTTER_API_VERSION', mutter_api_version)
|
||||
jsconf.set10('HAVE_NETWORKMANAGER', have_networkmanager)
|
||||
jsconf.set10('HAVE_PORTAL_HELPER', have_portal_helper)
|
||||
+jsconf.set('UTILS_FOLDER_APPS', run_command(
|
||||
+ generate_app_list, '../../data/default-apps/utilities-folder.txt',
|
||||
+ check: true,
|
||||
+).stdout())
|
||||
jsconf.set('datadir', datadir)
|
||||
jsconf.set('libexecdir', libexecdir)
|
||||
|
||||
diff --git a/js/ui/appDisplay.js b/js/ui/appDisplay.js
|
||||
index bdce3bdeed..992004b8f9 100644
|
||||
--- a/js/ui/appDisplay.js
|
||||
+++ b/js/ui/appDisplay.js
|
||||
@@ -24,6 +24,8 @@ import * as SystemActions from '../misc/systemActions.js';
|
||||
|
||||
import * as Main from './main.js';
|
||||
|
||||
+import {UTILITIES_FOLDER_APPS} from '../misc/config.js';
|
||||
+
|
||||
const MENU_POPUP_TIMEOUT = 600;
|
||||
const POPDOWN_DIALOG_TIMEOUT = 500;
|
||||
|
||||
@@ -60,22 +62,7 @@ const DEFAULT_FOLDERS = {
|
||||
'Utilities': {
|
||||
name: 'X-GNOME-Utilities.directory',
|
||||
categories: ['X-GNOME-Utilities'],
|
||||
- apps: [
|
||||
- 'org.freedesktop.GnomeAbrt.desktop',
|
||||
- 'nm-connection-editor.desktop',
|
||||
- 'org.gnome.baobab.desktop',
|
||||
- 'org.gnome.Connections.desktop',
|
||||
- 'org.gnome.DejaDup.desktop',
|
||||
- 'org.gnome.DiskUtility.desktop',
|
||||
- 'org.gnome.Evince.desktop',
|
||||
- 'org.gnome.FileRoller.desktop',
|
||||
- 'org.gnome.font-viewer.desktop',
|
||||
- 'org.gnome.Loupe.desktop',
|
||||
- 'org.freedesktop.MalcontentControl.desktop',
|
||||
- 'org.gnome.seahorse.Application.desktop',
|
||||
- 'org.gnome.tweaks.desktop',
|
||||
- 'org.gnome.Usage.desktop',
|
||||
- ],
|
||||
+ apps: UTILITIES_FOLDER_APPS,
|
||||
},
|
||||
'YaST': {
|
||||
name: 'suse-yast.directory',
|
||||
diff --git a/meson.build b/meson.build
|
||||
index c9955ca651..6f10a366bf 100644
|
||||
--- a/meson.build
|
||||
+++ b/meson.build
|
||||
@@ -137,6 +137,7 @@ endif
|
||||
mutter_typelibdir = mutter_dep.get_variable('typelibdir')
|
||||
python = find_program('python3')
|
||||
gjs = find_program('gjs')
|
||||
+generate_app_list = find_program('meson/generate-app-list.py')
|
||||
|
||||
cc = meson.get_compiler('c')
|
||||
|
||||
diff --git a/meson/generate-app-list.py b/meson/generate-app-list.py
|
||||
new file mode 100755
|
||||
index 0000000000..067c36967c
|
||||
--- /dev/null
|
||||
+++ b/meson/generate-app-list.py
|
||||
@@ -0,0 +1,40 @@
|
||||
+#!/usr/bin/env python3
|
||||
+
|
||||
+import argparse
|
||||
+
|
||||
+def read_app_ids(path) -> str:
|
||||
+ ids = []
|
||||
+ with open(path, "r") as file:
|
||||
+ for line in file:
|
||||
+ # strip comments
|
||||
+ line, _, _ = line.partition('#');
|
||||
+ line = line.strip()
|
||||
+ if len(line) > 0:
|
||||
+ ids.append(line)
|
||||
+ return ids
|
||||
+
|
||||
+def print_as_array(ids):
|
||||
+ mapped_ids = list(map(lambda i: f" '{i}'", ids))
|
||||
+ print('[')
|
||||
+ print(',\n'.join(mapped_ids))
|
||||
+ print(']')
|
||||
+
|
||||
+def print_as_pages(ids):
|
||||
+ mapped_ids = []
|
||||
+ for i, id in enumerate(ids):
|
||||
+ mapped_ids.append(f" '{id}': <{{'position': <{i}>}}>")
|
||||
+
|
||||
+ print('[{')
|
||||
+ print(',\n'.join(mapped_ids))
|
||||
+ print('}]')
|
||||
+
|
||||
+parser = argparse.ArgumentParser()
|
||||
+parser.add_argument('--pages', action='store_true')
|
||||
+parser.add_argument('file')
|
||||
+args = parser.parse_args()
|
||||
+
|
||||
+ids = read_app_ids(args.file)
|
||||
+if args.pages:
|
||||
+ print_as_pages(ids)
|
||||
+else:
|
||||
+ print_as_array(ids)
|
||||
--
|
||||
2.48.1
|
||||
|
||||
|
||||
From aeb7adf061d74d75edc85f65520cb404e8a4361d Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Fri, 14 Feb 2025 15:44:30 +0100
|
||||
Subject: [PATCH 2/3] data: Tweak dash/app-grid defaults
|
||||
|
||||
With the current RHEL 10 app set, the dash and app grid look
|
||||
rather empty.
|
||||
|
||||
Address this by
|
||||
- adding Calculator to dash
|
||||
- moving Characters and Baobab out of the Utilities folder
|
||||
|
||||
With those changes, there are at least 5 apps in the dash and 2 rows
|
||||
in the app grid.
|
||||
---
|
||||
data/default-apps/dash.txt | 1 +
|
||||
data/default-apps/utilities-folder.txt | 2 --
|
||||
2 files changed, 1 insertion(+), 2 deletions(-)
|
||||
|
||||
diff --git a/data/default-apps/dash.txt b/data/default-apps/dash.txt
|
||||
index 2a8e8bcd06..d0c2c21eb8 100644
|
||||
--- a/data/default-apps/dash.txt
|
||||
+++ b/data/default-apps/dash.txt
|
||||
@@ -4,3 +4,4 @@ org.gnome.Music.desktop
|
||||
gnome.Nautilus.desktop
|
||||
org.gnome.Software.desktop
|
||||
org.gnome.TextEditor.desktop
|
||||
+org.gnome.Calculator.desktop
|
||||
diff --git a/data/default-apps/utilities-folder.txt b/data/default-apps/utilities-folder.txt
|
||||
index 6169977751..187e3cfc54 100644
|
||||
--- a/data/default-apps/utilities-folder.txt
|
||||
+++ b/data/default-apps/utilities-folder.txt
|
||||
@@ -1,10 +1,8 @@
|
||||
# Sorted by name as shown in menus, not filename
|
||||
nm-connection-editor.desktop # Advanced Network Configuration
|
||||
org.gnome.DejaDup.desktop # Backups
|
||||
-org.gnome.Characters.desktop # Characters
|
||||
org.gnome.Connections.desktop # Connections
|
||||
org.gnome.DiskUtility.desktop # Disks
|
||||
-org.gnome.baobab.desktop # Disk Usage Analyzer
|
||||
org.gnome.Evince.desktop # Document Viewer
|
||||
org.gnome.FileRoller.desktop # File Roller
|
||||
org.gnome.font-viewer.desktop # Fonts
|
||||
--
|
||||
2.48.1
|
||||
|
||||
|
||||
From 7a21fca2f59d68896f54600b64e5d9a216203e9e Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Fri, 7 Feb 2025 15:54:15 +0100
|
||||
Subject: [PATCH 3/3] appDisplay: Filter apps in default folder
|
||||
|
||||
We currently create the default folder with the corresponding
|
||||
app list, regardless of whether the apps are actually part of
|
||||
the default install or not.
|
||||
|
||||
This matters when a user explicitly install such an app later,
|
||||
as it will be hidden away in the folder rather than appended
|
||||
to the app grid as expected.
|
||||
|
||||
To avoid that, only add currently-installed apps to the folder
|
||||
when creating it.
|
||||
|
||||
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3632>
|
||||
---
|
||||
js/ui/appDisplay.js | 8 ++++++--
|
||||
1 file changed, 6 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/js/ui/appDisplay.js b/js/ui/appDisplay.js
|
||||
index 992004b8f9..6bd2d899cd 100644
|
||||
--- a/js/ui/appDisplay.js
|
||||
+++ b/js/ui/appDisplay.js
|
||||
@@ -1419,12 +1419,16 @@ class AppDisplay extends BaseAppView {
|
||||
if (this._folderSettings.get_strv('folder-children').length > 0)
|
||||
return;
|
||||
|
||||
+ const appSys = Shell.AppSystem.get_default();
|
||||
const folders = Object.keys(DEFAULT_FOLDERS);
|
||||
this._folderSettings.set_strv('folder-children', folders);
|
||||
|
||||
const {path} = this._folderSettings;
|
||||
for (const folder of folders) {
|
||||
const {name, categories, apps} = DEFAULT_FOLDERS[folder];
|
||||
+ const filteredApps = apps
|
||||
+ ? apps.filter(id => appSys.lookup_app(id) != null)
|
||||
+ : [];
|
||||
const child = new Gio.Settings({
|
||||
schema_id: 'org.gnome.desktop.app-folders.folder',
|
||||
path: `${path}folders/${folder}/`,
|
||||
@@ -1432,8 +1436,8 @@ class AppDisplay extends BaseAppView {
|
||||
child.set_string('name', name);
|
||||
child.set_boolean('translate', true);
|
||||
child.set_strv('categories', categories);
|
||||
- if (apps)
|
||||
- child.set_strv('apps', apps);
|
||||
+ if (filteredApps.length > 0)
|
||||
+ child.set_strv('apps', filteredApps);
|
||||
}
|
||||
}
|
||||
|
||||
--
|
||||
2.48.1
|
||||
|
||||
Loading…
Reference in New Issue
Block a user