(self, event, *args)
Dispatch an event to the proper handler method.

        In the most common usage, this method is not overloaded by subclasses,
        as it performs the routing of events to methods. However, this
        method can be overridden if special dispatching rules are needed, or if
        having a single method that catches all events is desired.
Dispatch an event to the proper handler method.
Dispatch an event to the proper handler method .
def trigger_event(self, event, *args):
        """Dispatch an event to the proper handler method.

        In the most common usage, this method is not overloaded by subclasses,
        as it performs the routing of events to methods. However, this
        method can be overridden if special dispatching rules are needed, or if
        having a single method that catches all events is desired.
        """
        handler_name = 'on_' + event
        if hasattr(self, handler_name):
            return getattr(self, handler_name)(*args)
def trigger_event ( self , event , * args ) : handler_name = 'on_' + event if hasattr ( self , handler_name ) : return getattr ( self , handler_name ) ( * args )