Mercurial > libervia-backend
diff src/sat.tac @ 262:af3d4f11fe43
Added management of connection error
- core: connection_error signal is sent if it's impossible to connect
- bridge: added connection_error signal
- quick_frontend: an error_message is shown when a connection_error is received
author | Goffi <goffi@goffi.org> |
---|---|
date | Sat, 22 Jan 2011 15:53:56 +0100 |
parents | c8406fe5e81e |
children | 27bc5d7732a3 |
line wrap: on
line diff
--- a/src/sat.tac Tue Jan 18 15:22:58 2011 +0100 +++ b/src/sat.tac Sat Jan 22 15:53:56 2011 +0100 @@ -106,6 +106,15 @@ self.disco.requestInfo(jid.JID(self.host_app.memory.getParamA("Server", "Connection", profile_key=self.profile))).addCallback(self.host_app.serverDisco) #FIXME: use these informations + def initializationFailed(self, reason): + print ("initializationFailed: %s" % reason) + self.host_app.bridge.connection_error(self.profile,"AUTH_ERROR") + try: + client.XMPPClient.initializationFailed(self, reason) + except: + #we already send an error signal, no need to raise an exception + pass + def isConnected(self): return self.__connected