Ejemplo n.º 1
0
    def _populate(self):
        EventSystemEntity._populate(self)
        for event, argValues in self._LISTENERS.iteritems():
            self.addListener(event, *argValues)

        for handler in self.__packagesHandlers:
            handler.init()
Ejemplo n.º 2
0
    def _populate(self):
        EventSystemEntity._populate(self)
        for event, argValues in self._LISTENERS.iteritems():
            self.addListener(event, *argValues)

        for handler in self.__packagesHandlers:
            handler.init()
Ejemplo n.º 3
0
 def __init__(self, isColored, width, height):
     swf = 'keyboard.swf' if isColored else 'keyboardMono.swf'
     Flash.__init__(self, swf)
     EventSystemEntity.__init__(self)
     self.movie.wg_outputToLogitechLcd = True
     self.addListener(events.ShowViewEvent.SHOW_LOGIN, self.__showLogoScreen, EVENT_BUS_SCOPE.GLOBAL)
     self.addListener(events.ShowViewEvent.SHOW_LOBBY, self.__showStatsScreen, EVENT_BUS_SCOPE.GLOBAL)
     self.addListener(events.LoadEvent.LOAD_BATTLE_LOADING, self.__showBattleLoadingScreen, EVENT_BUS_SCOPE.LOBBY)
     self.addListener(events.LoadEvent.LOAD_TUTORIAL_LOADING, self.__showBattleLoadingScreen, EVENT_BUS_SCOPE.LOBBY)
Ejemplo n.º 4
0
 def __init__(self, isColored, width, height):
     swf = 'keyboard.swf' if isColored else 'keyboardMono.swf'
     Flash.__init__(self, swf)
     EventSystemEntity.__init__(self)
     self.movie.wg_outputToLogitechLcd = True
     self.addListener(VIEW_ALIAS.LOGIN, self.__showLogoScreen, EVENT_BUS_SCOPE.GLOBAL)
     self.addListener(VIEW_ALIAS.LOBBY, self.__showStatsScreen, EVENT_BUS_SCOPE.GLOBAL)
     self.addListener(VIEW_ALIAS.BATTLE_LOADING, self.__showBattleLoadingScreen, EVENT_BUS_SCOPE.LOBBY)
     self.addListener(VIEW_ALIAS.TUTORIAL_LOADING, self.__showBattleLoadingScreen, EVENT_BUS_SCOPE.LOBBY)
     connectionManager.onDisconnected += self.__onDisconnect
Ejemplo n.º 5
0
    def _dispose(self):
        for event, argValues in self._LISTENERS.iteritems():
            self.removeListener(event, *argValues)

        self.__lobbyHdlr.destroy()
        self.__lobbyHdlr = None
        self.__dlgsHdlr.destroy()
        self.__dlgsHdlr = None
        self._LISTENERS.clear()
        self._LISTENERS = None
        EventSystemEntity._dispose(self)
Ejemplo n.º 6
0
    def _dispose(self):
        for event, argValues in self._LISTENERS.iteritems():
            self.removeListener(event, *argValues)

        self.__lobbyHdlr.destroy()
        self.__lobbyHdlr = None
        self.__dlgsHdlr.destroy()
        self.__dlgsHdlr = None
        self._LISTENERS.clear()
        self._LISTENERS = None
        EventSystemEntity._dispose(self)
Ejemplo n.º 7
0
 def __init__(self, isColored, width, height):
     swf = 'keyboard.swf' if isColored else 'keyboardMono.swf'
     Flash.__init__(self, swf)
     EventSystemEntity.__init__(self)
     self.movie.wg_outputToLogitechLcd = True
     self.addListener(events.ShowViewEvent.SHOW_LOGIN,
                      self.__showLogoScreen, EVENT_BUS_SCOPE.GLOBAL)
     self.addListener(events.ShowViewEvent.SHOW_LOBBY,
                      self.__showStatsScreen, EVENT_BUS_SCOPE.GLOBAL)
     self.addListener(events.LoadEvent.LOAD_BATTLE_LOADING,
                      self.__showBattleLoadingScreen, EVENT_BUS_SCOPE.LOBBY)
     self.addListener(events.LoadEvent.LOAD_TUTORIAL_LOADING,
                      self.__showBattleLoadingScreen, EVENT_BUS_SCOPE.LOBBY)
Ejemplo n.º 8
0
    def _dispose(self):
        for event, argValues in self._LISTENERS.iteritems():
            self.removeListener(event, *argValues)

        self.__lobbyHdlr.destroy()
        self.__lobbyHdlr = None
        self.__dlgsHdlr.destroy()
        self.__dlgsHdlr = None
        self._LISTENERS.clear()
        self._LISTENERS = None
        while len(self.__packagesHandlers):
            self.__packagesHandlers.pop().fini()

        EventSystemEntity._dispose(self)
Ejemplo n.º 9
0
 def _populate(self):
     EventSystemEntity._populate(self)
     if self.isShow == False:
         return
     isShowFullEULA = GUI_SETTINGS.eula.full
     if isShowFullEULA:
         self.__eulaText = self.__readEULAFull()
         if not len(self.__eulaText):
             isShowFullEULA = False
     if not isShowFullEULA:
         self.__eulaText = self.__readEULAShort()
     if len(self.__eulaText):
         self.addListener(CloseWindowEvent.EULA_CLOSED, self.__onEulaClosed)
         self.fireEvent(LoadViewEvent(VIEW_ALIAS.EULA_FULL if isShowFullEULA else VIEW_ALIAS.EULA, ctx={'text': self.__eulaText}))
Ejemplo n.º 10
0
 def __init__(self, isColored, width, height):
     swf = 'keyboard.swf' if isColored else 'keyboardMono.swf'
     Flash.__init__(self, swf)
     EventSystemEntity.__init__(self)
     self.movie.wg_outputToLogitechLcd = True
     self.addListener(VIEW_ALIAS.LOGIN, self.__showLogoScreen,
                      EVENT_BUS_SCOPE.GLOBAL)
     self.addListener(VIEW_ALIAS.LOBBY, self.__showStatsScreen,
                      EVENT_BUS_SCOPE.GLOBAL)
     self.addListener(VIEW_ALIAS.BATTLE_LOADING,
                      self.__showBattleLoadingScreen, EVENT_BUS_SCOPE.LOBBY)
     self.addListener(VIEW_ALIAS.TUTORIAL_LOADING,
                      self.__showBattleLoadingScreen, EVENT_BUS_SCOPE.LOBBY)
     connectionManager.onDisconnected += self.__onDisconnect
Ejemplo n.º 11
0
 def _populate(self):
     EventSystemEntity._populate(self)
     if self.isShowLicense():
         isShowFullEULA = GUI_SETTINGS.eula.full
         if isShowFullEULA:
             self.__eulaText = self.__readEULAFull()
             if not len(self.__eulaText):
                 isShowFullEULA = False
         if not isShowFullEULA:
             self.__eulaText = self.__readEULAShort()
         if len(self.__eulaText):
             self.addListener(CloseWindowEvent.EULA_CLOSED, self.__onEulaClosed)
             self.fireEvent(ShowWindowEvent(ShowWindowEvent.SHOW_EULA, ctx={'isFull': isShowFullEULA,
              'text': self.__eulaText}))
Ejemplo n.º 12
0
 def _populate(self):
     EventSystemEntity._populate(self)
     if self.isShow is False:
         return
     isShowFullEULA = GUI_SETTINGS.eula.full
     if isShowFullEULA:
         self.__eulaText = self.__readEULAFull()
         if not self.__eulaText:
             isShowFullEULA = False
     if not isShowFullEULA:
         self.__eulaText = self.__readEULAShort()
     if self.__eulaText:
         self.addListener(CloseWindowEvent.EULA_CLOSED, self.__onEulaClosed)
         self.fireEvent(LoadViewEvent(SFViewLoadParams(VIEW_ALIAS.EULA_FULL if isShowFullEULA else VIEW_ALIAS.EULA), ctx={'text': self.__eulaText}), EVENT_BUS_SCOPE.LOBBY)
Ejemplo n.º 13
0
    def _dispose(self):
        for event, argValues in self._LISTENERS.iteritems():
            self.removeListener(event, *argValues)

        self.__lobbyHdlr.destroy()
        self.__lobbyHdlr = None
        self.__dlgsHdlr.destroy()
        self.__dlgsHdlr = None
        self._LISTENERS.clear()
        self._LISTENERS = None
        while len(self.__packagesHandlers):
            self.__packagesHandlers.pop().fini()

        EventSystemEntity._dispose(self)
        return
Ejemplo n.º 14
0
 def _populate(self):
     EventSystemEntity._populate(self)
     if self.isShow == False:
         return
     isShowFullEULA = GUI_SETTINGS.eula.full
     if isShowFullEULA:
         self.__eulaText = self.__readEULAFull()
         if not len(self.__eulaText):
             isShowFullEULA = False
     if not isShowFullEULA:
         self.__eulaText = self.__readEULAShort()
     if len(self.__eulaText):
         self.addListener(CloseWindowEvent.EULA_CLOSED, self.__onEulaClosed)
         self.fireEvent(
             LoadViewEvent(VIEW_ALIAS.EULA_FULL
                           if isShowFullEULA else VIEW_ALIAS.EULA,
                           ctx={'text': self.__eulaText}))
Ejemplo n.º 15
0
 def _populate(self):
     EventSystemEntity._populate(self)
     if self.isShowLicense():
         isShowFullEULA = GUI_SETTINGS.eula.full
         if isShowFullEULA:
             self.__eulaText = self.__readEULAFull()
             if not len(self.__eulaText):
                 isShowFullEULA = False
         if not isShowFullEULA:
             self.__eulaText = self.__readEULAShort()
         if len(self.__eulaText):
             self.addListener(CloseWindowEvent.EULA_CLOSED,
                              self.__onEulaClosed)
             self.fireEvent(
                 ShowWindowEvent(ShowWindowEvent.SHOW_EULA,
                                 ctx={
                                     'isFull': isShowFullEULA,
                                     'text': self.__eulaText
                                 }))
Ejemplo n.º 16
0
 def _populate(self):
     EventSystemEntity._populate(self)
     for event, argValues in self._LISTENERS.iteritems():
         self.addListener(event, *argValues)
Ejemplo n.º 17
0
 def _populate(self):
     EventSystemEntity._populate(self)
     for event, argValues in self._LISTENERS.iteritems():
         self.addListener(event, *argValues)