Add an option to enable restart/shutdown at lockscreen

Resolves: https://issues.redhat.com/browse/RHEL-103998
This commit is contained in:
Joan Torres Lopez 2025-07-15 18:09:49 +02:00
parent 0e6c855e75
commit ea4247c7b9
2 changed files with 43 additions and 1 deletions

View File

@ -0,0 +1,34 @@
From 3a33fed1a56dd3104a1718c91b55bb42bef215fa Mon Sep 17 00:00:00 2001
From: Joan Torres Lopez <joantolo@redhat.com>
Date: Tue, 15 Jul 2025 11:29:48 +0200
Subject: [PATCH] schema: Add 'restart-enabled' on screensaver schema
Originally restart/shutdown was always disabled at lockscreen.
This new setting allows to enable it if desired.
To keep the original state, the default is still disabled.
---
schemas/org.gnome.desktop.screensaver.gschema.xml.in | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/schemas/org.gnome.desktop.screensaver.gschema.xml.in b/schemas/org.gnome.desktop.screensaver.gschema.xml.in
index 5c2db2a..4cf7d3a 100644
--- a/schemas/org.gnome.desktop.screensaver.gschema.xml.in
+++ b/schemas/org.gnome.desktop.screensaver.gschema.xml.in
@@ -1,6 +1,13 @@
<?xml version="1.0" encoding="UTF-8"?>
<schemalist gettext-domain="gsettings-desktop-schemas">
<schema id="org.gnome.desktop.screensaver" path="/org/gnome/desktop/screensaver/">
+ <key name="restart-enabled" type="b">
+ <default>false</default>
+ <summary>Enable restart/shutdown</summary>
+ <description>
+ Allow shutdown and restart actions from the lock screen.
+ </description>
+ </key>
<key name="idle-activation-enabled" type="b">
<default>true</default>
<summary>Activate when idle</summary>
--
2.49.0

View File

@ -4,7 +4,7 @@
Name: gsettings-desktop-schemas
Version: 40.0
Release: 6%{?dist}
Release: 7%{?dist}
Summary: A collection of GSettings schemas
License: LGPLv2+
@ -12,6 +12,10 @@ License: LGPLv2+
URL: https://gitlab.gnome.org/GNOME/gsettings-desktop-schemas
Source0: https://download.gnome.org/sources/%{name}/40/%{name}-%{tarball_version}.tar.xz
# RHEL-103998
# https://gitlab.gnome.org/GNOME/gsettings-desktop-schemas/-/merge_requests/111
Patch: 0001-schema-Add-restart-enabled-on-screensaver-schema.patch
BuildRequires: gettext
BuildRequires: glib2-devel >= 2.31.0
BuildRequires: gobject-introspection-devel
@ -81,6 +85,10 @@ glib-compile-schemas --dry-run --strict %{buildroot}%{_datadir}/glib-2.0/schemas
%changelog
* Wed Jul 16 2025 Joan Torres <joantolo@redhat.com> - 40.0-7
- Add an option to enable restart/shutdown at lockscreen
Resolves: RHEL-103998
* Wed Dec 21 2022 Tomas Popela <tpopela@redhat.com> - 40.0-6
- Require the Source Code Pro font instead of only recommending it to not break
systems updated from 9.0.0.