mirror of
https://github.com/telegramdesktop/tdesktop
synced 2025-08-31 06:26:18 +00:00
Add items to overviews inside HistoryMedia.
This allows one history item to exist in several media overviews. See voice message, which should be in VoiceFiles and RoundVoiceFiles.
This commit is contained in:
@@ -1347,20 +1347,6 @@ bool MainWidget::preloadOverview(PeerData *peer, MediaOverviewType type) {
|
||||
return true;
|
||||
}
|
||||
|
||||
void MainWidget::preloadOverviews(PeerData *peer) {
|
||||
History *h = App::history(peer->id);
|
||||
bool sending = false;
|
||||
for (int32 i = 0; i < OverviewCount; ++i) {
|
||||
auto type = MediaOverviewType(i);
|
||||
if (type != OverviewChatPhotos && preloadOverview(peer, type)) {
|
||||
sending = true;
|
||||
}
|
||||
}
|
||||
if (sending) {
|
||||
MTP::sendAnything();
|
||||
}
|
||||
}
|
||||
|
||||
void MainWidget::overviewPreloaded(PeerData *peer, const MTPmessages_Messages &result, mtpRequestId req) {
|
||||
MediaOverviewType type = OverviewCount;
|
||||
for (int32 i = 0; i < OverviewCount; ++i) {
|
||||
|
Reference in New Issue
Block a user