From aac5c0bf1b9bcd6e7dddc8db1accb5aad77e5bc3 Mon Sep 17 00:00:00 2001 From: Yann Leboulanger Date: Wed, 1 Dec 2010 09:16:35 +0100 Subject: [PATCH] correctly dispatch our show events --- src/gui_interface.py | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/src/gui_interface.py b/src/gui_interface.py index 2d472e40a..4f223155d 100644 --- a/src/gui_interface.py +++ b/src/gui_interface.py @@ -1208,8 +1208,9 @@ class Interface: def on_cancel(): del self.instances[account]['online_dialog']['ssl_error'] - iobj.conn.disconnect(on_purpose=True) - self.handle_event_status(account, 'offline') + obj.conn.disconnect(on_purpose=True) + gajim.nec.push_incoming_event(OurShowEvent(None, conn=obj.conn, + show='offline') pritext = _('Error verifying SSL certificate') sectext = _('There was an error verifying the SSL certificate of your ' @@ -1242,7 +1243,8 @@ class Interface: def on_no(): del self.instances[account]['online_dialog']['fingerprint_error'] obj.conn.disconnect(on_purpose=True) - self.handle_event_status(account, 'offline') + gajim.nec.push_incoming_event(OurShowEvent(None, conn=obj.conn, + show='offline') pritext = _('SSL certificate error') sectext = _('It seems the SSL certificate of account %(account)s has ' @@ -1277,7 +1279,8 @@ class Interface: del self.instances[obj.conn.name]['online_dialog']\ ['plain_connection'] obj.conn.disconnect(on_purpose=True) - self.handle_event_status(obj.conn.name, 'offline') + gajim.nec.push_incoming_event(OurShowEvent(None, conn=obj.conn, + show='offline') pritext = _('Insecure connection') sectext = _('You are about to connect to the server with an insecure ' @@ -1316,7 +1319,8 @@ class Interface: def on_cancel(): del self.instances[obj.conn.name]['online_dialog']['insecure_ssl'] obj.conn.disconnect(on_purpose=True) - self.handle_event_status(obj.conn.name, 'offline') + gajim.nec.push_incoming_event(OurShowEvent(None, conn=obj.conn, + show='offline') pritext = _('Insecure connection') sectext = _('You are about to send your password on an insecure ' @@ -1357,7 +1361,8 @@ class Interface: del self.instances[obj.conn.name]['online_dialog']\ ['insecure_password'] obj.conn.disconnect(on_purpose=True) - self.handle_event_status(obj.conn.name, 'offline') + gajim.nec.push_incoming_event(OurShowEvent(None, conn=obj.conn, + show='offline') pritext = _('Insecure connection') sectext = _('You are about to send your password unencrypted on an '