2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 14:38:15 +00:00

Improve gift corner badge display.

This commit is contained in:
John Preston
2025-01-06 14:53:21 +04:00
parent 549de7fa54
commit e6060ea277
10 changed files with 295 additions and 153 deletions

View File

@@ -1528,7 +1528,7 @@ void SendGiftBox(
bool sending = false;
};
const auto state = raw->lifetime().make_state<State>(State{
.delegate = Delegate(window),
.delegate = Delegate(window, GiftButtonMode::Full),
});
const auto single = state->delegate.buttonSize();
const auto shadow = st::defaultDropdownMenu.wrap.shadow;
@@ -1575,7 +1575,7 @@ void SendGiftBox(
for (auto i = 0; i != count; ++i) {
const auto button = state->buttons[i].get();
const auto &descriptor = gifts.list[order[i]];
button->setDescriptor(descriptor);
button->setDescriptor(descriptor, GiftButton::Mode::Full);
const auto last = !((i + 1) % perRow);
if (last) {