[empathy] tls-dialog: destroy the dialog if the certificate is invalidated (#643186)
- From: Guillaume Desmottes <gdesmott src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [empathy] tls-dialog: destroy the dialog if the certificate is invalidated (#643186)
- Date: Thu, 24 Feb 2011 13:31:34 +0000 (UTC)
commit 677a6bf7fca3ce8e26cf02d36c2721fa03510a4d
Author: Guillaume Desmottes <guillaume desmottes collabora co uk>
Date: Thu Feb 24 14:29:22 2011 +0100
tls-dialog: destroy the dialog if the certificate is invalidated (#643186)
There is no point to keep it around.
libempathy-gtk/empathy-tls-dialog.c | 13 +++++++++++++
1 files changed, 13 insertions(+), 0 deletions(-)
---
diff --git a/libempathy-gtk/empathy-tls-dialog.c b/libempathy-gtk/empathy-tls-dialog.c
index f09d6c5..8f1f49e 100644
--- a/libempathy-gtk/empathy-tls-dialog.c
+++ b/libempathy-gtk/empathy-tls-dialog.c
@@ -257,6 +257,16 @@ checkbox_toggled_cb (GtkToggleButton *checkbox,
}
static void
+certificate_invalidated_cb (EmpathyTLSCertificate *certificate,
+ guint domain,
+ gint code,
+ gchar *message,
+ EmpathyTLSDialog *self)
+{
+ gtk_widget_destroy (GTK_WIDGET (self));
+}
+
+static void
empathy_tls_dialog_constructed (GObject *object)
{
GtkWidget *content_area, *expander, *details, *checkbox;
@@ -310,6 +320,9 @@ empathy_tls_dialog_constructed (GObject *object)
details = build_gcr_widget (self);
gtk_container_add (GTK_CONTAINER (expander), details);
gtk_widget_show (details);
+
+ tp_g_signal_connect_object (priv->certificate, "invalidated",
+ G_CALLBACK (certificate_invalidated_cb), self, 0);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]