forked from organicmaps/organicmaps
Merge pull request #2862 from syershov/fix-progress-for-serverlist
[downloader] Fix progress calculation while getting servers list
This commit is contained in:
commit
bc6b945b31
1 changed files with 5 additions and 0 deletions
|
@ -1333,7 +1333,12 @@ void Storage::GetNodeAttrs(TCountryId const & countryId, NodeAttrs & nodeAttrs)
|
|||
: kInvalidCountryId;
|
||||
MapFilesDownloader::TProgress downloadingMwmProgress(0, 0);
|
||||
if (!m_downloader->IsIdle())
|
||||
{
|
||||
downloadingMwmProgress = m_downloader->GetDownloadingProgress();
|
||||
// If we don't know estimated file size then we ignore its progress.
|
||||
if (downloadingMwmProgress.second == -1)
|
||||
downloadingMwmProgress = {0, 0};
|
||||
}
|
||||
|
||||
TCountriesSet setQueue;
|
||||
GetQueuedCountries(m_queue, setQueue);
|
||||
|
|
Loading…
Add table
Reference in a new issue