mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-08-31 14:38:15 +00:00
Update API scheme to layer 190.
Support adding messages to gifts of Premium subscriptions.
This commit is contained in:
@@ -1083,19 +1083,7 @@ void SendGiftBox(
|
||||
};
|
||||
button->setClickedCallback([=] {
|
||||
const auto star = std::get_if<GiftTypeStars>(&descriptor);
|
||||
if (v::is<GiftTypePremium>(descriptor)) {
|
||||
if (state->sending) {
|
||||
return;
|
||||
} else {
|
||||
state->sending = true;
|
||||
}
|
||||
SendGift(
|
||||
window,
|
||||
peer,
|
||||
api,
|
||||
GiftDetails{ descriptor },
|
||||
premiumSent);
|
||||
} else if (star && star->limitedCount && !star->limitedLeft) {
|
||||
if (star && star->limitedCount && !star->limitedLeft) {
|
||||
window->showToast({
|
||||
.title = tr::lng_gift_sold_out_title(tr::now),
|
||||
.text = tr::lng_gift_sold_out_text(
|
||||
|
Reference in New Issue
Block a user