2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-09-05 00:46:08 +00:00

Use new toast style structure.

This commit is contained in:
John Preston
2020-04-29 18:52:40 +04:00
parent 8a4c7e3994
commit dd78052f92
12 changed files with 78 additions and 59 deletions

View File

@@ -77,12 +77,11 @@ void ApplyArchivedResult(const MTPDmessages_stickerSetInstallResultArchive &d) {
Local::writeInstalledStickers();
Local::writeArchivedStickers();
auto toast = Ui::Toast::Config();
toast.text = { tr::lng_stickers_packs_archived(tr::now) };
toast.maxWidth = toast.minWidth = st::stickersToastMaxWidth;
toast.multiline = true;
toast.padding = st::stickersToastPadding;
Ui::Toast::Show(toast);
Ui::Toast::Show(Ui::Toast::Config{
.text = { tr::lng_stickers_packs_archived(tr::now) },
.st = &st::stickersToast,
.multiline = true,
});
// Ui::show(Box<StickersBox>(archived, &Auth()), Ui::LayerOption::KeepOther);
Auth().data().notifyStickersUpdated();