comparison libervia.py @ 422:20c508f9b32a

browser side: fixed bad use of Timer
author Goffi <goffi@goffi.org>
date Wed, 26 Mar 2014 17:34:01 +0100
parents fadbba1d793f
children 77d8f55fc5f0
comparison
equal deleted inserted replaced
421:39b07289ff42 422:20c508f9b32a
149 LiberviaJsonProxy.onRemoteError(self, code, errobj, request_info) 149 LiberviaJsonProxy.onRemoteError(self, code, errobj, request_info)
150 #we now try to reconnect 150 #we now try to reconnect
151 if isinstance(errobj['message'], dict) and errobj['message']['faultCode'] == 0: 151 if isinstance(errobj['message'], dict) and errobj['message']['faultCode'] == 0:
152 Window.alert('You are not allowed to connect to server') 152 Window.alert('You are not allowed to connect to server')
153 else: 153 else:
154 def _timerCb(): 154 def _timerCb(timer):
155 self.host.bridge_signals.call('getSignals', self.host._getSignalsCB) 155 self.host.bridge_signals.call('getSignals', self.host._getSignalsCB)
156 Timer(notify=_timerCb).schedule(self.retry_delay) 156 Timer(notify=_timerCb).schedule(self.retry_delay)
157 self.retry_delay *= 2 157 self.retry_delay *= 2
158 158
159 159