当前位置: 首页>>代码示例>>Python>>正文


Python gui.GUI_SETTINGS类代码示例

本文整理汇总了Python中gui.GUI_SETTINGS的典型用法代码示例。如果您正苦于以下问题:Python GUI_SETTINGS类的具体用法?Python GUI_SETTINGS怎么用?Python GUI_SETTINGS使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


在下文中一共展示了GUI_SETTINGS类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: getURL

 def getURL(self, name, callback):
     urlSettings = GUI_SETTINGS.lookup(name)
     if urlSettings:
         url = yield self.__urlMarcos.parse(str(urlSettings))
     else:
         url = yield lambda callback: callback('')
     callback(url)
开发者ID:webiumsk,项目名称:WOT-0.9.15.1,代码行数:7,代码来源:externallinkshandler.py

示例2: quality

 def quality(self):
     boosterQualityValues = GUI_SETTINGS.lookup(self.boosterGuiType) or _BOOSTER_QUALITY_VALUES
     if self.effectValue >= boosterQualityValues[BOOSTER_QUALITY_NAMES.BIG]:
         return BOOSTER_QUALITY_NAMES.BIG
     elif self.effectValue >= boosterQualityValues[BOOSTER_QUALITY_NAMES.MEDIUM]:
         return BOOSTER_QUALITY_NAMES.MEDIUM
     else:
         return BOOSTER_QUALITY_NAMES.SMALL
开发者ID:webiumsk,项目名称:WOT-0.9.12,代码行数:8,代码来源:booster.py

示例3: _getClubEmblemUrl

def _getClubEmblemUrl(emblemID, size):
    try:
        urlPattern = GUI_SETTINGS.lookup('clubEmblems')
        if urlPattern and emblemID:
            return urlPattern % {'emblemID': emblemID,
             'size': size}
    except:
        LOG_CURRENT_EXCEPTION()
开发者ID:kblw,项目名称:wot_client,代码行数:8,代码来源:emblems.py

示例4: showSecurityMessage

 def showSecurityMessage(self):
     if self.__securityMsgType is not None:
         securityLink = ''
         if not GUI_SETTINGS.isEmpty('securitySettingsURL'):
             linkText = makeString(SYSTEM_MESSAGES.SECURITYMESSAGE_CHANGE_SETINGS)
             securityLink = makeHtmlString('html_templates:lobby/system_messages', 'link', {'text': linkText,
              'linkType': 'securityLink'})
         SystemMessages.pushI18nMessage('#system_messages:securityMessage/%s' % self.__securityMsgType, type=SystemMessages.SM_TYPE.Warning, link=securityLink)
         self.__securityMsgType = None
开发者ID:kblw,项目名称:wot_client,代码行数:9,代码来源:logindispatcher.py

示例5: _showSecurityMessage

 def _showSecurityMessage(self, responseData):
     securityWarningType = responseData.get('security_msg')
     if securityWarningType is not None:
         securityLink = ''
         if not GUI_SETTINGS.isEmpty('securitySettingsURL'):
             securityLink = makeHtmlString('html_templates:lobby/system_messages', 'link', {'text': _ms(SYSTEM_MESSAGES.SECURITYMESSAGE_CHANGE_SETINGS),
              'linkType': 'securityLink'})
         SystemMessages.pushI18nMessage('#system_messages:securityMessage/%s' % securityWarningType, type=SystemMessages.SM_TYPE.Warning, link=securityLink)
     return
开发者ID:webiumsk,项目名称:WOT0.10.0,代码行数:9,代码来源:manager.py

示例6: createAppFactory

def createAppFactory():
    if GUI_SETTINGS.isGuiEnabled():
        if GUI_SETTINGS.useAS3Battle:
            factory = AS3_AppFactory()
        else:
            factory = AS3_AS2_AppFactory()
    else:
        factory = NoAppFactory()
    return factory
开发者ID:webiumsk,项目名称:WOT-0.9.14-CT,代码行数:9,代码来源:app_factory.py

示例7: init

def init(loadingScreenGUI = None):
    global onShopResyncStarted
    global onAccountShowGUI
    global onScreenShotMade
    global onIGRTypeChanged
    global onAccountBecomeNonPlayer
    global onAvatarBecomePlayer
    global onAccountBecomePlayer
    global onKickedFromServer
    global onShopResync
    g_loginManager.init()
    miniclient.configure_state()
    connectionManager.onKickedFromServer += onKickedFromServer
    g_playerEvents.onAccountShowGUI += onAccountShowGUI
    g_playerEvents.onAccountBecomeNonPlayer += onAccountBecomeNonPlayer
    g_playerEvents.onAccountBecomePlayer += onAccountBecomePlayer
    g_playerEvents.onAvatarBecomePlayer += onAvatarBecomePlayer
    g_playerEvents.onClientUpdated += onClientUpdate
    g_playerEvents.onShopResyncStarted += onShopResyncStarted
    g_playerEvents.onShopResync += onShopResync
    g_playerEvents.onCenterIsLongDisconnected += onCenterIsLongDisconnected
    g_playerEvents.onIGRTypeChanged += onIGRTypeChanged
    if GUI_SETTINGS.isGuiEnabled():
        from gui.Scaleform.app_factory import AS3_AS2_AppFactory as AppFactory
    else:
        from gui.Scaleform.app_factory import NoAppFactory as AppFactory
    g_appLoader.init(AppFactory())
    game_control.g_instance.init()
    from gui.Scaleform import SystemMessagesInterface
    SystemMessages.g_instance = SystemMessagesInterface.SystemMessagesInterface()
    SystemMessages.g_instance.init()
    ParametersCache.g_instance.init()
    if loadingScreenGUI and loadingScreenGUI.script:
        loadingScreenGUI.script.active(False)
    g_prbLoader.init()
    LogitechMonitor.init()
    g_itemsCache.init()
    g_settingsCache.init()
    g_settingsCore.init()
    g_eventsCache.init()
    g_clanCache.init()
    g_clubsCtrl.init()
    g_clanCtrl.init()
    g_vehicleProgressCache.init()
    g_goodiesCache.init()
    BigWorld.wg_setScreenshotNotifyCallback(onScreenShotMade)
    from constants import IS_DEVELOPMENT
    if IS_DEVELOPMENT:
        try:
            from gui.development import init
        except ImportError:
            LOG_ERROR('Development features not found.')
            init = lambda : None

        init()
    guiModsInit()
开发者ID:webiumsk,项目名称:WOT0.10.0,代码行数:56,代码来源:personality.py

示例8: canChangeWebSettings

 def canChangeWebSettings(self, profile, club = None):
     url = GUI_SETTINGS.lookup('clubSettings')
     if not url:
         return error(_CCR.DEFAULT)
     else:
         if club is not None:
             permissions = club.getPermissions()
             if not permissions.canChangeWebSettings():
                 return error(_CCR.DEFAULT)
             if club.getTotalDossier().getTotalStats().getBattlesCount() < CLUB_LIMITS.MIN_BATTLES_COUNT_TO_CHANGE_NAME:
                 return error(_CCR.NOT_ENOUGH_RATED_BATTLES)
         return success()
开发者ID:krzcho,项目名称:WOTDecompiled,代码行数:12,代码来源:restrictions.py

示例9: canChangeWebSettings

    def canChangeWebSettings(self, profile, club = None):
        url = GUI_SETTINGS.lookup('clubSettings')
        if not url:
            return error(_CCR.DEFAULT)
        if club is not None:
            for rID in {_CRT.CHANGE_CLUB_NAME, _CRT.CHANGE_CLUB_EMBLEM}:
                result = self._isClubRequestValid(rID, club, 'canChangeWebSettings')
                if result.success:
                    return result

            return error(_CCR.NOT_ENOUGH_RATED_BATTLES)
        return success()
开发者ID:kblw,项目名称:wot_client,代码行数:12,代码来源:restrictions.py

示例10: createAim

def createAim(type):
    if not GUI_SETTINGS.isGuiEnabled():
        from gui.development.no_gui.battle import Aim
        return Aim()
    if type == 'strategic':
        return StrategicAim((0, 0.0))
    if type == 'arcade':
        return ArcadeAim((0, 0.15), False)
    if type == 'sniper':
        return ArcadeAim((0, 0.0), True)
    if type == 'postmortem':
        return PostMortemAim((0, 0.0))
    LOG_ERROR('Undefined aim type. <%s>' % type)
开发者ID:Infernux,项目名称:Projects,代码行数:13,代码来源:aims.py

示例11: showSecurityMessage

 def showSecurityMessage(self):
     if self.__securityMsgType is not None:
         securityLink = ""
         if not GUI_SETTINGS.isEmpty("securitySettingsURL"):
             linkText = makeString(SYSTEM_MESSAGES.SECURITYMESSAGE_CHANGE_SETINGS)
             securityLink = makeHtmlString(
                 "html_templates:lobby/system_messages", "link", {"text": linkText, "linkType": "securityLink"}
             )
         SystemMessages.pushI18nMessage(
             "#system_messages:securityMessage/%s" % self.__securityMsgType,
             type=SystemMessages.SM_TYPE.Warning,
             link=securityLink,
         )
         self.__securityMsgType = None
     return
开发者ID:webiumsk,项目名称:WOT-0.9.12-CT,代码行数:15,代码来源:logindispatcher.py

示例12: __init__

 def __init__(self, proxy):
     super(EncyclopediaController, self).__init__(proxy)
     self.__activated = False
     self.__recommendations = []
     self.__eventManager = Event.EventManager()
     self.__urlMacros = URLMarcos()
     self.__isLobbyStarted = False
     self.__hasNewRecommendations = False
     if GUI_SETTINGS.lookup('encyclopedia'):
         self.__baseUrl = GUI_SETTINGS.encyclopedia['url']
         self.__isSuitableLanguage = GUI_SETTINGS.encyclopedia['enabled']
     else:
         self.__baseUrl = None
         self.__isSuitableLanguage = False
     self.onNewRecommendationReceived = Event.Event(self.__eventManager)
     self.onStateChanged = Event.Event(self.__eventManager)
     self.__isStateSynced = False
     return
开发者ID:aevitas,项目名称:wotsdk,代码行数:18,代码来源:game_controlprmp_controller.py

示例13: showPostMortem

        self.window.fireEvent(LoadViewEvent(eventType), scope=EVENT_BUS_SCOPE.LOBBY)
        return

    def showPostMortem(self):
        LogitechMonitor.onScreenChange('postmortem')
        if self.__battleWindow:
            self.__battleWindow.showPostmortemTips()

    def showBotsMenu(self):
        try:
            from gui.development.ui.BotsMenu import BotsMenu
            BotsMenu(self.__battleWindow).active(True)
        except ImportError:
            from debug_utils import LOG_ERROR
            LOG_ERROR('BotsMenu not found.')

    def __onAppStarted(self, event):
        if BattleReplay.g_replayCtrl.autoStartBattleReplay() or connectionManager.isConnected():
            return
        if not self.__startVideoShown:
            self.__startVideoShown = True
            if self.showStartGameVideo():
                return
        self.showLogin()


if GUI_SETTINGS.isGuiEnabled():
    g_windowsManager = WindowsManager()
else:
    from gui.development.no_gui.WindowsManager import WindowsManager
    g_windowsManager = WindowsManager()
开发者ID:krzcho,项目名称:WOTDecompiled,代码行数:31,代码来源:windowsmanager.py

示例14: changeAccount

 def changeAccount(self):
     self.__rememberMe = False
     self.as_setDefaultValuesS('', '', False, GUI_SETTINGS.rememberPassVisible, GUI_SETTINGS.igrCredentialsReset, not GUI_SETTINGS.isEmpty('recoveryPswdURL'))
     self.__showRequiredLoginScreen()
     self.as_setErrorMessageS(self.__socialNetworkLogin.getLogoutWarning(self.__lastLoginType), 0)
     self.__loginPreferences.writeString('login', '')
     self.__loginPreferences.writeBool('rememberPwd', False)
     self.__loginPreferences.writeString('lastLoginType', 'basic')
     self.__loginPreferences.writeString('token2', '')
     self.__loginPreferences.writeString('user', '')
开发者ID:kblw,项目名称:wot_client,代码行数:10,代码来源:__init__.py

示例15: onHandleInvalidPasswordWithToken

 def onHandleInvalidPasswordWithToken(self, user, rememberPwd):
     self.__showRequiredLoginScreen()
     self.as_setDefaultValuesS(user, '', rememberPwd, GUI_SETTINGS.rememberPassVisible, GUI_SETTINGS.igrCredentialsReset, not GUI_SETTINGS.isEmpty('recoveryPswdURL'))
开发者ID:kblw,项目名称:wot_client,代码行数:3,代码来源:__init__.py


注:本文中的gui.GUI_SETTINGS类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。