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

Simplified FileOriginStory.

This commit is contained in:
23rd
2023-11-22 07:55:58 +03:00
committed by John Preston
parent 32008161a0
commit 0865776d9a
5 changed files with 10 additions and 34 deletions

View File

@@ -269,9 +269,7 @@ Main::Session &PhotoThumbnail::session() {
StoryThumbnail::Thumb PhotoThumbnail::loaded(FullStoryId id) {
if (!_media) {
_media = _photo->createMediaView();
_media->wanted(
Data::PhotoSize::Small,
Data::FileOriginStory(id.peer, id.story));
_media->wanted(Data::PhotoSize::Small, id);
}
if (const auto small = _media->image(Data::PhotoSize::Small)) {
return { .image = small };
@@ -297,7 +295,7 @@ Main::Session &VideoThumbnail::session() {
StoryThumbnail::Thumb VideoThumbnail::loaded(FullStoryId id) {
if (!_media) {
_media = _video->createMediaView();
_media->thumbnailWanted(Data::FileOriginStory(id.peer, id.story));
_media->thumbnailWanted(id);
}
if (const auto small = _media->thumbnail()) {
return { .image = small };