From 808e8dcf4f5d7a819a29bb3ddd2c55e29becd201 Mon Sep 17 00:00:00 2001 From: John Preston Date: Tue, 15 Sep 2020 14:46:54 +0300 Subject: [PATCH] Inject discussed message in Replies section. --- Telegram/SourceFiles/data/data_replies_list.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Telegram/SourceFiles/data/data_replies_list.cpp b/Telegram/SourceFiles/data/data_replies_list.cpp index ae5798e949..6b892c163c 100644 --- a/Telegram/SourceFiles/data/data_replies_list.cpp +++ b/Telegram/SourceFiles/data/data_replies_list.cpp @@ -205,6 +205,11 @@ bool RepliesList::buildFromData(not_null viewer) { for (auto j = i - useAfter, e = i + useBefore; j != e; ++j) { slice->ids.emplace_back(channelId, *j); } + if (slice->skippedBefore == 0) { + if (const auto root = lookupRoot()) { + slice->ids.push_back(root->fullId()); + } + } ranges::reverse(slice->ids); slice->fullCount = _fullCount.current();