def handler(message): # TODO: this result count be expandable, but we have no way to allow the # user to interact with the balloon to expand it. body = message['body'] result = body['result'] if result is None: result = 'null' display = [ 'Type: ' + body.get('type', '<unknown>'), 'Value: ' + result ] utils.DisplayBaloon(self._is_term, display)
def handler(message): # TODO: this result count be expandable, but we have no way to allow the # user to interact with the balloon to expand it, unless we use a popup # instead, but even then we don't really want to trap the cursor. body = message['body'] result = body['result'] if result is None: result = 'null' display = [ 'Type: ' + body.get('type', '<unknown>'), 'Value: ' + result ] utils.DisplayBaloon(self._is_term, display)
def failure_handler(reason, message): display = [reason] utils.DisplayBaloon(self._is_term, display)