def __init__(self, arg, **kwargs): Image.__init__(self, arg, **kwargs) EventDispatcher.__init__(self) self.register_event_type('on_load')
def __new__(cls, **kwargs): if cls.__instance is None: cls.__instance = EventDispatcher.__new__(cls) return cls.__instance