[epiphany/mcatanzaro/#1570] passwords-view: fix the Clear All action
- From: Michael Catanzaro <mcatanzaro src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [epiphany/mcatanzaro/#1570] passwords-view: fix the Clear All action
- Date: Sun, 1 Aug 2021 14:24:08 +0000 (UTC)
commit 3b6e8462b20490173ea6d72489a4e62651beeb1b
Author: Michael Catanzaro <mcatanzaro redhat com>
Date: Sun Aug 1 09:16:16 2021 -0500
passwords-view: fix the Clear All action
Apparently people don't try to delete all their passwords very often,
because this has been broken for the past year and nobody noticed until
now. Whatever. The dialog is no longer a GtkWindow so we just have to
find the parent window instead.
Fixes #1570
src/preferences/passwords-view.c | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
---
diff --git a/src/preferences/passwords-view.c b/src/preferences/passwords-view.c
index b4df843af..66d0fe2d4 100644
--- a/src/preferences/passwords-view.c
+++ b/src/preferences/passwords-view.c
@@ -183,9 +183,13 @@ confirmation_dialog_response_cb (GtkWidget *dialog,
static GtkWidget *
confirmation_dialog_construct (EphyPasswordsView *self)
{
- GtkWidget *dialog, *button;
+ GtkWidget *dialog;
+ GtkWidget *button;
+ GtkWidget *window;
- dialog = gtk_message_dialog_new (GTK_WINDOW (self),
+ window = gtk_widget_get_toplevel (GTK_WIDGET (self));
+
+ dialog = gtk_message_dialog_new (GTK_WINDOW (window),
GTK_DIALOG_MODAL | GTK_DIALOG_DESTROY_WITH_PARENT,
GTK_MESSAGE_WARNING,
GTK_BUTTONS_CANCEL,
@@ -194,7 +198,7 @@ confirmation_dialog_construct (EphyPasswordsView *self)
gtk_message_dialog_format_secondary_text (GTK_MESSAGE_DIALOG (dialog),
_("This will clear all locally stored passwords, and can not be
undone."));
- gtk_window_group_add_window (ephy_gui_ensure_window_group (GTK_WINDOW (self)),
+ gtk_window_group_add_window (ephy_gui_ensure_window_group (GTK_WINDOW (window)),
GTK_WINDOW (dialog));
button = gtk_button_new_with_mnemonic (_("_Delete"));
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]