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

Support feeds search display in dialogs list.

This commit is contained in:
John Preston
2018-02-14 22:38:01 +03:00
parent 98fb874b29
commit 0f775e1e66
16 changed files with 393 additions and 201 deletions

View File

@@ -149,13 +149,17 @@ void activateBotCommand(
}
void searchByHashtag(const QString &tag, PeerData *inPeer) {
if (MainWidget *m = main()) {
if (const auto m = main()) {
Ui::hideSettingsAndLayer();
Messenger::Instance().hideMediaView();
if (inPeer && (!inPeer->isChannel() || inPeer->isMegagroup())) {
inPeer = nullptr;
}
m->searchMessages(tag + ' ', inPeer);
m->searchMessages(
tag + ' ',
(inPeer
? App::history(inPeer).get()
: nullptr));
}
}