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

Add IV icon to the button.

This commit is contained in:
John Preston
2024-03-12 17:56:42 +04:00
parent 7b4adc2e60
commit d43f0be0da
9 changed files with 95 additions and 29 deletions

View File

@@ -3544,9 +3544,13 @@ void Session::webpageApplyFields(
process(block, process);
}
}
const auto type = story ? WebPageType::Story : ParseWebPageType(data);
auto iv = (data.vcached_page() && !IgnoreIv(type))
? std::make_unique<Iv::Data>(data, *data.vcached_page())
: nullptr;
webpageApplyFields(
page,
(story ? WebPageType::Story : ParseWebPageType(data)),
type,
qs(data.vurl()),
qs(data.vdisplay_url()),
siteName,
@@ -3564,9 +3568,7 @@ void Session::webpageApplyFields(
? processDocument(*document).get()
: lookupThemeDocument()),
WebPageCollage(this, data),
(data.vcached_page()
? std::make_unique<Iv::Data>(data, *data.vcached_page())
: nullptr),
std::move(iv),
data.vduration().value_or_empty(),
qs(data.vauthor().value_or_empty()),
data.is_has_large_media(),