From 30044eb60cd2c21733c6a856c10e9fd3d068c044 Mon Sep 17 00:00:00 2001 From: Alexander Boriskov Date: Wed, 2 Dec 2020 17:07:10 +0300 Subject: [PATCH] [iOS] Fixed duplicate banner creation in downloader screen https://jira.mail.ru/browse/MAPSME-15224 --- iphone/Maps/Classes/Widgets/MWMMapDownloadDialog.mm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/iphone/Maps/Classes/Widgets/MWMMapDownloadDialog.mm b/iphone/Maps/Classes/Widgets/MWMMapDownloadDialog.mm index 9758df002f..a3acf22149 100644 --- a/iphone/Maps/Classes/Widgets/MWMMapDownloadDialog.mm +++ b/iphone/Maps/Classes/Widgets/MWMMapDownloadDialog.mm @@ -99,7 +99,6 @@ using namespace storage; } - (void)configDialog { - [self removePreviousBunnerIfNeeded]; auto &f = GetFramework(); auto const &s = f.GetStorage(); auto const &p = f.GetDownloadingPolicy(); @@ -126,6 +125,7 @@ using namespace storage; switch (nodeAttrs.m_status) { case NodeStatus::NotDownloaded: case NodeStatus::Partly: { + [self removePreviousBunnerIfNeeded]; MapViewController *controller = self.controller; BOOL const isMapVisible = [controller.navigationController.topViewController isEqual:controller]; if (isMapVisible && !self.isAutoDownloadCancelled && canAutoDownload(m_countryId)) { @@ -163,6 +163,7 @@ using namespace storage; case NodeStatus::Undefined: case NodeStatus::Error: if (p.IsAutoRetryDownloadFailed()) { + [self removePreviousBunnerIfNeeded]; [self showError:nodeAttrs.m_error]; } else { [self showInQueue];