2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-31 06:26:18 +00:00

Support collapsible blockquotes in Ui::Text::String.

This commit is contained in:
John Preston
2024-05-30 15:05:13 +04:00
parent 974bf99921
commit 40fbd415ef
16 changed files with 84 additions and 31 deletions

View File

@@ -1820,12 +1820,19 @@ rpl::producer<not_null<HistoryItem*>> Session::itemDataChanges() const {
}
void Session::requestItemTextRefresh(not_null<HistoryItem*> item) {
if (const auto i = _views.find(item); i != _views.end()) {
for (const auto &view : i->second) {
view->itemTextUpdated();
const auto call = [&](not_null<HistoryItem*> item) {
if (const auto i = _views.find(item); i != _views.end()) {
for (const auto &view : i->second) {
view->itemTextUpdated();
}
}
requestItemResize(item);
};
if (const auto group = groups().find(item)) {
call(group->items.front());
} else {
call(item);
}
requestItemResize(item);
}
void Session::registerHighlightProcess(