示例#1
0
 def onAfterAutoLoginTimerClearing(self, host, clearInFlash):
     urls = g_preDefinedHosts.urlIterator(host)
     if urls is not None:
         urls.resume()
     self.__minOrderInQueue = 18446744073709551615L
     if clearInFlash:
         self.fireEvent(LoginEvent(LoginEvent.CANCEL_LGN_QUEUE, View.alias))
示例#2
0
 def onAfterAutoLoginTimerClearing(self, host, clearInFlash):
     urls = g_preDefinedHosts.urlIterator(host)
     if urls is not None:
         urls.resume()
     self.__minOrderInQueue = 18446744073709551615L
     if clearInFlash:
         self.fireEvent(LoginEvent(LoginEvent.CANCEL_LGN_QUEUE, View.alias))
示例#3
0
 def handleLoginRejectedRateLimited(self, status, message):
     errorMessage = i18n.makeString(MENU.LOGIN_STATUS_LOGIN_REJECTED_RATE_LIMITED)
     self.onSetStatus(errorMessage, self.ALL_VALID)
     urls = g_preDefinedHosts.urlIterator(self.__loginDataLoader.host)
     if urls is not None and urls.end():
         urls.cursor = 0
     message = i18n.makeString(WAITING.MESSAGE_AUTOLOGIN, connectionManager.serverUserName)
     self.onHandleLoginRejectedRateLimited(message)
     self.__setAutoLoginTimer(self.__getLgNextTimeout())
示例#4
0
 def __loginToNextLoginApp(self):
     urls = g_preDefinedHosts.urlIterator(self.__loginDataLoader.host)
     result = False
     if urls is not None:
         result = not urls.end()
         if result:
             Waiting.hide('login')
             self.__setAutoLoginTimer(0)
         else:
             urls.cursor = 0
     return result
示例#5
0
 def __loginToNextLoginApp(self):
     urls = g_preDefinedHosts.urlIterator(self.__loginDataLoader.host)
     result = False
     if urls is not None:
         result = not urls.end()
         if result:
             Waiting.hide('login')
             self.__setAutoLoginTimer(0)
         else:
             urls.cursor = 0
     return result
示例#6
0
 def handleLoginRejectedRateLimited(self, status, message):
     errorMessage = i18n.makeString(
         MENU.LOGIN_STATUS_LOGIN_REJECTED_RATE_LIMITED)
     self.onSetStatus(errorMessage, self.ALL_VALID)
     urls = g_preDefinedHosts.urlIterator(self.__loginDataLoader.host)
     if urls is not None and urls.end():
         urls.cursor = 0
     message = i18n.makeString(WAITING.MESSAGE_AUTOLOGIN,
                               connectionManager.serverUserName)
     self.onHandleLoginRejectedRateLimited(message)
     self.__setAutoLoginTimer(self.__getLgNextTimeout())
示例#7
0
 def handleKickWhileLogin(self, peripheryID):
     if peripheryID < 0:
         self.__kickPeripheryID = peripheryID
         return
     g_preDefinedHosts.savePeripheryTL(peripheryID)
     self.__kickedFromServer = True
     messageType = 'another_periphery' if peripheryID else 'checkout_error'
     errorMessage = i18n.makeString(SYSTEM_MESSAGES.all(messageType))
     self.onSetStatus(errorMessage, self.ALL_VALID)
     urls = g_preDefinedHosts.urlIterator(self.__loginDataLoader.host)
     if urls is not None and urls.end():
         urls.cursor = 0
     message = i18n.makeString(WAITING.message(messageType), connectionManager.serverUserName)
     self.onHandleKickWhileLogin(messageType, message)
     self.__setAutoLoginTimer(self.__getLgNextTimeout())
示例#8
0
 def handleKickWhileLogin(self, peripheryID):
     if peripheryID < 0:
         self.__kickPeripheryID = peripheryID
         return
     g_preDefinedHosts.savePeripheryTL(peripheryID)
     self.__kickedFromServer = True
     messageType = 'another_periphery' if peripheryID else 'checkout_error'
     errorMessage = i18n.makeString(SYSTEM_MESSAGES.all(messageType))
     self.onSetStatus(errorMessage, self.ALL_VALID)
     urls = g_preDefinedHosts.urlIterator(self.__loginDataLoader.host)
     if urls is not None and urls.end():
         urls.cursor = 0
     message = i18n.makeString(WAITING.message(messageType),
                               connectionManager.serverUserName)
     self.onHandleKickWhileLogin(messageType, message)
     self.__setAutoLoginTimer(self.__getLgNextTimeout())