[gnome-control-center/users-show-autologin-row-when-locked] user-accounts: Show "automatic login" option when locked
- From: Felipe Borges <felipeborges src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-control-center/users-show-autologin-row-when-locked] user-accounts: Show "automatic login" option when locked
- Date: Mon, 4 Jul 2022 09:34:05 +0000 (UTC)
commit b3f1497f1d3d2960003d2a1284cf92f1044bc156
Author: Felipe Borges <felipeborges gnome org>
Date: Mon Jul 4 11:32:43 2022 +0200
user-accounts: Show "automatic login" option when locked
It should be made insensitive when the panel is locked, and sensitive
when locked.
We only hide this row for non-local users, where this setting doesn't
make much sense.
Fixes #1944
panels/user-accounts/cc-user-panel.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/panels/user-accounts/cc-user-panel.c b/panels/user-accounts/cc-user-panel.c
index d2481a48f..e88e1d6c5 100644
--- a/panels/user-accounts/cc-user-panel.c
+++ b/panels/user-accounts/cc-user-panel.c
@@ -1278,7 +1278,10 @@ on_permission_changed (CcUserPanel *self)
gtk_widget_set_visible (GTK_WIDGET (self->account_type_row), TRUE);
}
- gtk_widget_set_visible (GTK_WIDGET (self->autologin_row), get_autologin_possible (user));
+ if (get_autologin_possible (user)) {
+ gtk_widget_set_visible (GTK_WIDGET (self->autologin_row), TRUE);
+ gtk_widget_set_sensitive (GTK_WIDGET (self->autologin_row), TRUE);
+ }
}
else {
gtk_widget_set_visible (GTK_WIDGET (self->account_type_row), FALSE);
@@ -1287,7 +1290,7 @@ on_permission_changed (CcUserPanel *self)
} else {
gtk_widget_set_visible (GTK_WIDGET (self->account_type_row), TRUE);
}
- gtk_widget_set_visible (GTK_WIDGET (self->autologin_row), FALSE);
+ gtk_widget_set_sensitive (GTK_WIDGET (self->autologin_row), FALSE);
add_unlock_tooltip (GTK_WIDGET (self->autologin_row));
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]