Ejemplo n.º 1
0
 def __tryToInvokeRegisterEvent(self, step):
     prevSteps = self.__state
     self.__state |= step
     if prevSteps != self.__state and self.__state == _ExternalComponentState.INITED:
         g_eventBus.handleEvent(events.ComponentEvent(
             events.ComponentEvent.COMPONENT_REGISTERED, self.owner, self,
             self.alias),
                                scope=EVENT_BUS_SCOPE.GLOBAL)
Ejemplo n.º 2
0
 def __invokeUnregisterEvent(self):
     if self.__state & _ExternalComponentState.REGISTERED > 0:
         self.__state ^= _ExternalComponentState.REGISTERED
         self.__state |= _ExternalComponentState.UNREGISTERED
         g_eventBus.handleEvent(events.ComponentEvent(
             events.ComponentEvent.COMPONENT_UNREGISTERED, self.owner, self,
             self.alias),
                                scope=EVENT_BUS_SCOPE.GLOBAL)
Ejemplo n.º 3
0
 def invokeRegisterComponentForReplay(self):
     g_eventBus.handleEvent(events.ComponentEvent(
         events.ComponentEvent.COMPONENT_REGISTERED, self.owner, self,
         self.alias),
                            scope=EVENT_BUS_SCOPE.GLOBAL)
Ejemplo n.º 4
0
 def __fireRegisteringEvent(self, event, componentPy, alias):
     g_eventBus.handleEvent(events.ComponentEvent(event, self, componentPy, alias), EVENT_BUS_SCOPE.GLOBAL)