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


Python settings.SelectedNation类代码示例

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


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

示例1: _resolveLoadCtx

 def _resolveLoadCtx(self, ctx=None):
     nation = ctx["nation"] if ctx is not None and "nation" in ctx else None
     if nation is not None and nation in nations.INDICES:
         nationIdx = nations.INDICES[nation]
         SelectedNation.select(nationIdx)
     else:
         SelectedNation.byDefault()
开发者ID:kblw,项目名称:wot_client,代码行数:7,代码来源:techtree.py

示例2: getNationTreeData

 def getNationTreeData(self, nationName):
     if nationName not in nations.INDICES:
         LOG_ERROR('Nation not found', nationName)
         return {}
     nationIdx = nations.INDICES[nationName]
     SelectedNation.select(nationIdx)
     self._data.load(nationIdx, override=self._getOverride())
     return self._data.dump()
开发者ID:webiumsk,项目名称:WOT-0.9.12-CT,代码行数:8,代码来源:techtree.py

示例3: _resolveLoadCtx

 def _resolveLoadCtx(self, ctx = None):
     rootCD = ctx['rootCD'] if ctx is not None and 'rootCD' in ctx else None
     if rootCD is None:
         if g_currentVehicle.isPresent():
             self._data.setRootCD(g_currentVehicle.item.intCD)
     else:
         self._data.setRootCD(rootCD)
     SelectedNation.select(self._data.getNationID())
开发者ID:kblw,项目名称:wot_client,代码行数:8,代码来源:research.py

示例4: getNationTreeData

 def getNationTreeData(self, nationName):
     """
     Overridden method of the class _Py_ScriptHandler.getNationTreeData.
     """
     if nationName not in nations.INDICES:
         LOG_ERROR('Nation not found', nationName)
         return {}
     nationIdx = nations.INDICES[nationName]
     SelectedNation.select(nationIdx)
     self._data.load(nationIdx, override=self._getOverride())
     return self._data.dump()
开发者ID:aevitas,项目名称:wotsdk,代码行数:11,代码来源:techtreetechtree.py

示例5: dump

 def dump(self, data):
     self.clear()
     nodes = data._nodes
     itemGetter = data.getItem
     self._cache['nodes'] = map(lambda node: self._getVehicleData(node, itemGetter(node['id'])), nodes)
     self._cache['scrollIndex'] = data._scrollIndex
     self._cache['displaySettings'].update(g_techTreeDP.getDisplaySettings(SelectedNation.getIndex()))
     return self._cache
开发者ID:kblw,项目名称:wot_client,代码行数:8,代码来源:dumpers.py

示例6: requestNationTreeData

 def requestNationTreeData(self):
     """
     Overridden method of the class _Py_ScriptHandler.requestNationTreeData.
     """
     if USE_XML_DUMPING and IS_DEVELOPMENT:
         self.as_useXMLDumpingS()
     self.as_setAvailableNationsS(g_techTreeDP.getAvailableNations())
     self.as_setSelectedNationS(SelectedNation.getName())
     return True
开发者ID:aevitas,项目名称:wotsdk,代码行数:9,代码来源:techtreetechtree.py

示例7: invalidateVehLocks

 def invalidateVehLocks(self, locks):
     if self._data.invalidateLocks(locks):
         self.as_refreshNationTreeDataS(SelectedNation.getName())
开发者ID:webiumsk,项目名称:WOT-0.9.12-CT,代码行数:3,代码来源:techtree.py

示例8: goToNextVehicle

 def goToNextVehicle(self, vehCD):
     exitEvent = events.LoadViewEvent(VIEW_ALIAS.LOBBY_TECHTREE, ctx={'nation': SelectedNation.getName()})
     loadEvent = events.LoadViewEvent(VIEW_ALIAS.LOBBY_RESEARCH, ctx={'rootCD': vehCD,
      'exit': exitEvent})
     self.fireEvent(loadEvent, scope=EVENT_BUS_SCOPE.LOBBY)
开发者ID:webiumsk,项目名称:WOT-0.9.12-CT,代码行数:5,代码来源:techtree.py

示例9: requestNationTreeData

 def requestNationTreeData(self):
     if USE_XML_DUMPING and IS_DEVELOPMENT:
         self.as_useXMLDumpingS()
     self.as_setAvailableNationsS(g_techTreeDP.getAvailableNations())
     self.as_setSelectedNationS(SelectedNation.getName())
     return True
开发者ID:webiumsk,项目名称:WOT-0.9.12-CT,代码行数:6,代码来源:techtree.py

示例10: redraw

 def redraw(self):
     self.as_refreshNationTreeDataS(SelectedNation.getName())
开发者ID:webiumsk,项目名称:WOT-0.9.12-CT,代码行数:2,代码来源:techtree.py

示例11: __handleReloadData

 def __handleReloadData(self, event):
     if event.key is Keys.KEY_R:
         g_techTreeDP.load(isReload=True)
         self.as_refreshNationTreeDataS(SelectedNation.getName())
开发者ID:webiumsk,项目名称:WOT-0.9.12-CT,代码行数:4,代码来源:techtree.py

示例12: __onUpdateStage

 def __onUpdateStage(self):
     g_techTreeDP.setOverride(self._getOverride())
     if g_techTreeDP.load():
         self.as_refreshNationTreeDataS(SelectedNation.getName())
开发者ID:webiumsk,项目名称:WOT-0.9.12-CT,代码行数:4,代码来源:techtree.py


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