Kalev Lember 2022-09-21 22:26:15 +02:00
parent d5e018f2c0
commit 6a829fd8e4

View File

@ -1,12 +1,10 @@
From 70f3343835d6f125eaf47637d64e593409119b59 Mon Sep 17 00:00:00 2001
From ad548a4731512e1aa3daf2de83fd8d1d1ac7a5bb Mon Sep 17 00:00:00 2001
From: Kalev Lember <klember@redhat.com>
Date: Thu, 15 Sep 2022 11:58:06 +0200
Subject: [PATCH] account: Fix entry validation in enterprise login dialog
Subject: [PATCH 1/3] account: Fix entry validation in enterprise login dialog
Fix the password and domain validation to work again and not spew
criticals after the gtk 4 port.
Closes #154
---
.../account/gis-account-page-enterprise.c | 20 +++++++++++++++----
1 file changed, 16 insertions(+), 4 deletions(-)
@ -73,3 +71,80 @@ index 7b119950..87a12bc8 100644
--
GitLab
From c33e55e620099c560eba804d345ec3e79e85ccaa Mon Sep 17 00:00:00 2001
From: Kalev Lember <klember@redhat.com>
Date: Wed, 21 Sep 2022 22:00:21 +0200
Subject: [PATCH 2/3] account: Clear password validation errors when entering
new password
Get rid of the red outline as soon as the user starts typing a new
password.
---
.../pages/account/gis-account-page-enterprise.c | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/gnome-initial-setup/pages/account/gis-account-page-enterprise.c b/gnome-initial-setup/pages/account/gis-account-page-enterprise.c
index 87a12bc8..8fdc3188 100644
--- a/gnome-initial-setup/pages/account/gis-account-page-enterprise.c
+++ b/gnome-initial-setup/pages/account/gis-account-page-enterprise.c
@@ -742,6 +742,13 @@ on_entry_changed (GtkEditable *editable,
clear_entry_validation_error (GTK_ENTRY (editable));
}
+static void
+on_password_changed (GtkEditable *editable,
+ gpointer user_data)
+{
+ clear_password_validation_error (GTK_WIDGET (editable));
+}
+
static void
gis_account_page_enterprise_realize (GtkWidget *widget)
{
@@ -776,6 +783,10 @@ gis_account_page_enterprise_constructed (GObject *object)
G_CALLBACK (on_domain_changed), page);
g_signal_connect (page->login, "changed",
G_CALLBACK (on_entry_changed), page);
+ g_signal_connect (page->password, "changed",
+ G_CALLBACK (on_password_changed), page);
+ g_signal_connect (page->join_password, "changed",
+ G_CALLBACK (on_password_changed), page);
}
static void
--
GitLab
From 43b415ce575b0b9d2b89404ddb3d3daa3c93b4ac Mon Sep 17 00:00:00 2001
From: Kalev Lember <klember@redhat.com>
Date: Wed, 21 Sep 2022 22:01:32 +0200
Subject: [PATCH 3/3] account: Fix swapped button responses in enterprise login
dialog
The Cancel button was acting as OK and vice-versa.
Closes #154
---
.../pages/account/gis-account-page-enterprise.ui | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/gnome-initial-setup/pages/account/gis-account-page-enterprise.ui b/gnome-initial-setup/pages/account/gis-account-page-enterprise.ui
index d60e69e7..e5ef0db5 100644
--- a/gnome-initial-setup/pages/account/gis-account-page-enterprise.ui
+++ b/gnome-initial-setup/pages/account/gis-account-page-enterprise.ui
@@ -265,8 +265,8 @@
</object>
</child>
<action-widgets>
- <action-widget response="-5">button_cancel</action-widget>
- <action-widget response="-6" default="true">button_ok</action-widget>
+ <action-widget response="-5" default="true">button_ok</action-widget>
+ <action-widget response="-6">button_cancel</action-widget>
</action-widgets>
</object>
<object class="GtkListStore" id="realms_model">
--
GitLab