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

Update API scheme to layer 143.

This commit is contained in:
John Preston
2022-05-10 18:22:28 +04:00
parent dd05fb4d14
commit 6dedf7c63e
81 changed files with 595 additions and 458 deletions

View File

@@ -756,7 +756,7 @@ float64 DocumentData::progress() const {
if (uploading()) {
if (uploadingData->size > 0) {
const auto result = float64(uploadingData->offset)
/ uploadingData->size;
/ float64(uploadingData->size);
return std::clamp(result, 0., 1.);
}
return 0.;
@@ -764,7 +764,7 @@ float64 DocumentData::progress() const {
return loading() ? _loader->currentProgress() : 0.;
}
int DocumentData::loadOffset() const {
int64 DocumentData::loadOffset() const {
return loading() ? _loader->currentOffset() : 0;
}