2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-08-31 14:45:14 +00:00

Improve search-in-topic closing.

This commit is contained in:
John Preston
2022-10-27 11:35:35 +04:00
parent 5d76415a5d
commit 850746b0ba
3 changed files with 31 additions and 16 deletions

View File

@@ -575,6 +575,17 @@ void SessionNavigation::showPeerInfo(
showPeerInfo(_session->data().peer(peerId), params);
}
void SessionNavigation::showTopic(
not_null<Data::ForumTopic*> topic,
MsgId commentId,
const SectionShow &params) {
return showRepliesForMessage(
topic->history(),
topic->rootId(),
commentId,
params);
}
void SessionNavigation::showPeerInfo(
not_null<PeerData*> peer,
const SectionShow &params) {
@@ -1539,9 +1550,8 @@ void SessionController::showCalendar(Dialogs::Key chat, QDate requestedDate) {
SectionShow::Way::Forward,
id);
} else if (const auto strongTopic = weakTopic.get()) {
strong->showRepliesForMessage(
strongTopic->history(),
strongTopic->rootId(),
strong->showTopic(
strongTopic,
id,
SectionShow::Way::Forward);
strong->hideLayer(anim::type::normal);