From 34f9f74040c9a4be9f838bbab0e4b474f1cdfc7ce87d2e7dc0ef7e75aaf645f7 Mon Sep 17 00:00:00 2001 From: Dominique Leuenberger Date: Fri, 24 May 2024 06:55:45 +0000 Subject: [PATCH] Accepting request 1176653 from home:xiaoguang_wang:branches:GNOME:Factory - Add gnome-control-center-users-page-Don-t-show-the-system-accounts.patch: not show system account in Users panel (bsc#1224199 glgo#GNOME/Settings#3066). OBS-URL: https://build.opensuse.org/request/show/1176653 OBS-URL: https://build.opensuse.org/package/show/GNOME:Factory/gnome-control-center?expand=0&rev=555 --- ...-page-Don-t-show-the-system-accounts.patch | 30 +++++++++++++++++++ gnome-control-center.changes | 7 +++++ gnome-control-center.spec | 3 ++ 3 files changed, 40 insertions(+) create mode 100644 gnome-control-center-users-page-Don-t-show-the-system-accounts.patch diff --git a/gnome-control-center-users-page-Don-t-show-the-system-accounts.patch b/gnome-control-center-users-page-Don-t-show-the-system-accounts.patch new file mode 100644 index 0000000..3f6f737 --- /dev/null +++ b/gnome-control-center-users-page-Don-t-show-the-system-accounts.patch @@ -0,0 +1,30 @@ +From cf0a84f2a79d3685b0f7a516e4c9d9ade1b888dc Mon Sep 17 00:00:00 2001 +From: Xiaoguang Wang +Date: Thu, 23 May 2024 09:32:43 +0800 +Subject: [PATCH] users-page: Don't show the system accounts + +When handling user-added signal, omit the system accounts. + +Fixes https://gitlab.gnome.org/GNOME/gnome-control-center/-/issues/3066 +--- + panels/system/users/cc-users-page.c | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/panels/system/users/cc-users-page.c b/panels/system/users/cc-users-page.c +index 56dd0e007..0d487558a 100644 +--- a/panels/system/users/cc-users-page.c ++++ b/panels/system/users/cc-users-page.c +@@ -168,6 +168,10 @@ on_user_added (CcUsersPage *self, + CcUserPage *page; + g_list_store_insert_sorted (self->model, user, sort_users, self); + ++ if (act_user_is_system_account (user)) { ++ return; ++ } ++ + page = CC_USER_PAGE (adw_navigation_view_get_visible_page (self->navigation)); + if (page != self->current_user_page) + return; +-- +2.45.1 + diff --git a/gnome-control-center.changes b/gnome-control-center.changes index 2d4fa19..e97d8c6 100644 --- a/gnome-control-center.changes +++ b/gnome-control-center.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Fri May 24 02:33:07 UTC 2024 - Xiaoguang Wang + +- Add gnome-control-center-users-page-Don-t-show-the-system-accounts.patch: + not show system account in Users panel + (bsc#1224199 glgo#GNOME/Settings#3066). + ------------------------------------------------------------------- Mon May 13 23:02:40 UTC 2024 - Richard Rahl diff --git a/gnome-control-center.spec b/gnome-control-center.spec index 93eef25..048e1a2 100644 --- a/gnome-control-center.spec +++ b/gnome-control-center.spec @@ -37,6 +37,8 @@ Source99: %{name}-rpmlintrc # PATCH-FIX-OPENSUSE gnome-control-center-disable-error-message-for-NM.patch bsc#989801 sckang@suse.com -- network: Improve the check for whether NM or wicked is running Patch1: gnome-control-center-disable-error-message-for-NM.patch +# PATCH-FIX-UPSTREAM gnome-control-center-users-page-Don-t-show-the-system-accounts.patch bsc#1224199 glgo#GNOME/Settings#3066 xwang@suse.com -- not show system account in Users panel +Patch2: gnome-control-center-users-page-Don-t-show-the-system-accounts.patch ### patches for Leap >= 15 plus SLE >= 15, but not TW # PATCH-FEATURE-SLE gnome-control-center-info-never-use-gnome-software.patch bsc#999336 fezhang@suse.com -- info: Never search for gnome-software as an option when checking for updates on SLE and Leap 42.2, because we use gpk-update-viewer. @@ -195,6 +197,7 @@ GNOME control center. %prep %setup -q %patch -P 1 -p1 +%patch -P 2 -p1 # patches for Leap >= 15 plus SLE >= 15, but not TW %if 0%{?sle_version} >= 150000