def _runResponse(self, evt):
"""Passes on a response from the net thread.
Called from wx main loop on reception of an wxEVT_RESPONSE"""
d = maybeDeferred(evt.func, *evt.params, **evt.kwparams)
if evt.onSuccess:
def onDone(r):
simpleCommand((evt.onSuccess, (r,), {}))
d.addCallback(onDone)
if evt.onFailure:
def onFail(r):
simpleCommand((evt.onFailure, (r,), {}))
d.addErrback(onFail)
# Methods called from net thread
评论列表
文章目录