code: def dispatchEvent(self, event, *args):
          
          for callback in self.listeners[event]:
              yield callback(event, self, *args)
docs: Fire all callbacks assigned to a particular event. To be called by
          derivative classes.
          :param *args: Additional arguments to be passed to the callback
          function.