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

Detect and send supports_streaming bit for videos.

This commit is contained in:
John Preston
2018-11-07 18:07:20 +04:00
parent a2b04c9d71
commit ef38572d5a
9 changed files with 137 additions and 5 deletions

View File

@@ -582,6 +582,9 @@ void FileLoadTask::process() {
attributes.push_back(MTP_documentAttributeAnimated());
}
auto flags = MTPDdocumentAttributeVideo::Flags(0);
if (video->supportsStreaming) {
flags |= MTPDdocumentAttributeVideo::Flag::f_supports_streaming;
}
attributes.push_back(MTP_documentAttributeVideo(MTP_flags(flags), MTP_int(video->duration), MTP_int(coverWidth), MTP_int(coverHeight)));
goodThumbnail = video->thumbnail;