def __setBuyingPanelInitData(self): self.as_setBuyingPanelInitDataS({'totalPriceLabel': text_styles.highTitle(MENU.CUSTOMIZATION_LABELS_TOTALPRICE), 'buyBtnLabel': MENU.CUSTOMIZATION_BUTTONS_APPLY, 'buyingListIcon': RES_ICONS.MAPS_ICONS_LIBRARY_ICON_BUTTON_LIST, 'goldIcon': RES_ICONS.MAPS_ICONS_LIBRARY_GOLDICON_1, 'creditsIcon': RES_ICONS.MAPS_ICONS_LIBRARY_CREDITSICON_1, 'purchasesBtnTooltip': makeTooltip(TOOLTIPS.CUSTOMIZATION_PURCHASESPOPOVERBTN_HEADER, TOOLTIPS.CUSTOMIZATION_PURCHASESPOPOVERBTN_BODY), 'buyingPanelVO': {'totalPriceCredits': text_styles.creditsTextBig(g_customizationController.carousel.slots.cart.totalPriceCredits), 'totalPriceGold': text_styles.goldTextBig(g_customizationController.carousel.slots.cart.totalPriceGold)}})
def formatPriceCredits(value): if g_itemsCache.items.stats.credits >= value: return text_styles.creditsTextBig(value) else: return formatPriceAlert(value)
def formatCreditPriceBig(value): value = BigWorld.wg_getIntegralFormat(value) icon = gui_icons.makeImageTag(RES_ICONS.MAPS_ICONS_LIBRARY_CREDITSICON_1, vSpace=-1) return '{} {}'.format(text_styles.creditsTextBig(value), icon)
def formatPriceCredits(value, itemsCache=None): if itemsCache is None or itemsCache.items.stats.credits >= value: return text_styles.creditsTextBig(value) else: return formatPriceAlert(value) return
def _makeBonus(value, bonusType): return {'icon': backport.image(R.images.gui.maps.icons.squad.bonuses.dyn(bonusType)()), 'bonusValue': text_styles.creditsTextBig(str(int(round(value))) + backport.text(R.strings.common.common.percent())), 'label': text_styles.playerOnline(backport.text(R.strings.messenger.dialogs.squadChannel.bonuses.dyn(bonusType)())), 'tooltipType': None, 'tooltip': None}