Exemplo n.º 1
0
 def commit_async(self, msg, callback=None, data=None):
     # TODO in generic baseclass have this default to using
     # commit() + the wrapper call the callback
     #~ print '!! ASYNC COMMIT'
     operation = AsyncOperation(self._commit, (msg,),
         lock=self._lock, callback=callback, data=data)
     operation.start()
Exemplo n.º 2
0
 def _start_async_operation(self):
     args = self.async_queue[0]
     operation = AsyncOperation(
         self._create_thumbnail, args=args, callback=self._async_callback, data=self.async_queue[0])
     operation.start()