From dcb98ce0fba0edb35d1dcd68b3514657964dc61b Mon Sep 17 00:00:00 2001 From: John Preston Date: Tue, 7 Jan 2025 13:24:56 +0400 Subject: [PATCH] WebPage open button doesn't inflate the preview. --- .../history/view/media/history_view_web_page.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/Telegram/SourceFiles/history/view/media/history_view_web_page.cpp b/Telegram/SourceFiles/history/view/media/history_view_web_page.cpp index 8d3c31c4b..9264327f4 100644 --- a/Telegram/SourceFiles/history/view/media/history_view_web_page.cpp +++ b/Telegram/SourceFiles/history/view/media/history_view_web_page.cpp @@ -649,11 +649,7 @@ QSize WebPage::countOptimalSize() { if (!_openButton.isEmpty()) { const auto w = rect::m::sum::h(st::historyPageButtonPadding) + _openButton.maxWidth(); - if (sponsored) { - accumulate_max(maxWidth, w); - } else { - maxWidth += w; - } + accumulate_max(maxWidth, w); } maxWidth += rect::m::sum::h(padding); minHeight += rect::m::sum::v(padding);