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

Update API scheme to layer 93. Broken.

This commit is contained in:
John Preston
2019-01-03 18:39:19 +04:00
parent 47edb71a68
commit d2d6b319b6
38 changed files with 486 additions and 463 deletions

View File

@@ -749,24 +749,26 @@ void FileLoadTask::process() {
attributes[0] = MTP_documentAttributeAudio(MTP_flags(flags), MTP_int(_duration), MTPstring(), MTPstring(), MTP_bytes(documentWaveformEncode5bit(_waveform)));
attributes.resize(1);
document = MTP_document(
MTP_flags(0),
MTP_long(_id),
MTP_long(0),
MTP_bytes(QByteArray()),
MTP_int(unixtime()),
MTP_string(filemime),
MTP_int(filesize),
thumbSize,
MTP_vector<MTPPhotoSize>(1, thumbSize),
MTP_int(MTP::maindc()),
MTP_vector<MTPDocumentAttribute>(attributes));
} else if (_type != SendMediaType::Photo) {
document = MTP_document(
MTP_flags(0),
MTP_long(_id),
MTP_long(0),
MTP_bytes(QByteArray()),
MTP_int(unixtime()),
MTP_string(filemime),
MTP_int(filesize),
thumbSize,
MTP_vector<MTPPhotoSize>(1, thumbSize),
MTP_int(MTP::maindc()),
MTP_vector<MTPDocumentAttribute>(attributes));
_type = SendMediaType::File;