diff options
Diffstat (limited to 'backends')
-rw-r--r-- | backends/cloud/savessyncrequest.cpp | 10 | ||||
-rw-r--r-- | backends/cloud/savessyncrequest.h | 4 | ||||
-rw-r--r-- | backends/cloud/storage.cpp | 2 |
3 files changed, 9 insertions, 7 deletions
diff --git a/backends/cloud/savessyncrequest.cpp b/backends/cloud/savessyncrequest.cpp index c7572c78f9..b952681bff 100644 --- a/backends/cloud/savessyncrequest.cpp +++ b/backends/cloud/savessyncrequest.cpp @@ -296,10 +296,12 @@ double SavesSyncRequest::getProgress() { return (double)(_totalFilesToHandle - _filesToDownload.size() - _filesToUpload.size()) / (double)(_totalFilesToHandle); } -Common::Array<Common::String> SavesSyncRequest::getFilesToUpload() { - Common::Array<Common::String> result = _filesToUpload; - if (_currentUploadingFile != "") - result.push_back(_currentUploadingFile); +Common::Array<Common::String> SavesSyncRequest::getFilesToDownload() { + Common::Array<Common::String> result; + for (uint32 i = 0; i < _filesToDownload.size(); ++i) + result.push_back(_filesToDownload[i].name()); + if (_currentDownloadingFile.name() != "") + result.push_back(_currentDownloadingFile.name()); return result; } diff --git a/backends/cloud/savessyncrequest.h b/backends/cloud/savessyncrequest.h index ad656107c9..6e74688493 100644 --- a/backends/cloud/savessyncrequest.h +++ b/backends/cloud/savessyncrequest.h @@ -71,8 +71,8 @@ public: /** Returns a number in range [0, 1], where 1 is "complete". */ double getProgress(); - /** Returns an array of saves names which are not uploaded yet. */ - Common::Array<Common::String> getFilesToUpload(); + /** Returns an array of saves names which are not downloaded yet. */ + Common::Array<Common::String> getFilesToDownload(); }; } // End of namespace Cloud diff --git a/backends/cloud/storage.cpp b/backends/cloud/storage.cpp index 95786c2cba..c1719d97b1 100644 --- a/backends/cloud/storage.cpp +++ b/backends/cloud/storage.cpp @@ -137,7 +137,7 @@ Common::Array<Common::String> Storage::getSyncingFiles() { Common::Array<Common::String> result; _runningRequestsMutex.lock(); if (_savesSyncRequest) - result = _savesSyncRequest->getFilesToUpload(); + result = _savesSyncRequest->getFilesToDownload(); _runningRequestsMutex.unlock(); return result; } |