mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-04-18 07:07:08 +02:00
Added decimal separators to count of credits in balances of owned bot.
This commit is contained in:
parent
119f109904
commit
057222757b
3 changed files with 4 additions and 4 deletions
Telegram/SourceFiles
|
@ -1664,7 +1664,7 @@ void Controller::fillBotCreditsButton() {
|
|||
auto &lifetime = _controls.buttonsLayout->lifetime();
|
||||
const auto state = lifetime.make_state<State>();
|
||||
if (const auto balance = _peer->session().credits().balance(_peer->id)) {
|
||||
state->balance = QString::number(balance);
|
||||
state->balance = Lang::FormatCountDecimal(balance);
|
||||
}
|
||||
|
||||
const auto wrap = _controls.buttonsLayout->add(
|
||||
|
@ -1689,7 +1689,7 @@ void Controller::fillBotCreditsButton() {
|
|||
if (data.balance) {
|
||||
wrap->toggle(true, anim::type::normal);
|
||||
}
|
||||
state->balance = QString::number(data.balance);
|
||||
state->balance = Lang::FormatCountDecimal(data.balance);
|
||||
});
|
||||
}
|
||||
{
|
||||
|
|
|
@ -124,7 +124,7 @@ void InnerWidget::fill() {
|
|||
return _state.availableBalance;
|
||||
})
|
||||
);
|
||||
auto valueToString = [](uint64 v) { return QString::number(v); };
|
||||
auto valueToString = [](uint64 v) { return Lang::FormatCountDecimal(v); };
|
||||
|
||||
if (data.revenueGraph.chart) {
|
||||
Ui::AddSkip(container);
|
||||
|
|
|
@ -926,7 +926,7 @@ rpl::producer<uint64> AddCreditsAction(
|
|||
name->setMarkedText(
|
||||
base::duplicate(icon)
|
||||
.append(QChar(' '))
|
||||
.append(QString::number(balance)),
|
||||
.append(Lang::FormatCountDecimal(balance)),
|
||||
Core::MarkedTextContext{
|
||||
.session = &user->session(),
|
||||
.customEmojiRepaint = [=] { name->update(); },
|
||||
|
|
Loading…
Add table
Reference in a new issue