GUI: Show bytes sizes in saves sync dialog
And also makes percentage calculated based on bytes sizes, not files count.
This commit is contained in:
parent
645e1a0c83
commit
85739018fe
7 changed files with 80 additions and 3 deletions
|
@ -109,7 +109,11 @@ void SaveLoadCloudSyncProgressDialog::pollCloudMan() {
|
|||
_close = true;
|
||||
}
|
||||
|
||||
_percentLabel->setLabel(Common::String::format("%u %%", progress));
|
||||
Common::String downloaded, downloadedUnits, total, totalUnits;
|
||||
downloaded = getHumanReadableBytes(CloudMan.getSyncDownloadBytesNumber(), downloadedUnits);
|
||||
total = getHumanReadableBytes(CloudMan.getSyncDownloadTotalBytesNumber(), totalUnits);
|
||||
|
||||
_percentLabel->setLabel(Common::String::format("%u %% (%s %S / %s %S)", progress, downloaded.c_str(), _(downloadedUnits).c_str(), total.c_str(), _(totalUnits).c_str()));
|
||||
_progressBar->setValue(progress);
|
||||
_progressBar->markAsDirty();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue