2
0
mirror of https://github.com/telegramdesktop/tdesktop synced 2025-08-30 22:16:14 +00:00

Suggest converting to gigagroup.

This commit is contained in:
John Preston
2021-02-19 17:53:20 +04:00
parent 47d2ecf629
commit 221b896117
9 changed files with 134 additions and 63 deletions

View File

@@ -2049,6 +2049,20 @@ MsgId Session::nextLocalMessageId() {
return _localMessageIdCounter++;
}
void Session::setSuggestToGigagroup(
not_null<ChannelData*> group,
bool suggest) {
if (suggest) {
_suggestToGigagroup.emplace(group);
} else {
_suggestToGigagroup.remove(group);
}
}
bool Session::suggestToGigagroup(not_null<ChannelData*> group) const {
return _suggestToGigagroup.contains(group);
}
HistoryItem *Session::message(ChannelId channelId, MsgId itemId) const {
if (!itemId) {
return nullptr;