From ca38b304f44fa4a02281f294515152baaa53ebae Mon Sep 17 00:00:00 2001 From: Victor Shcherb Date: Sat, 28 Apr 2018 18:03:14 +0300 Subject: [PATCH] Update download card --- .../plus/wikivoyage/explore/ExploreTabFragment.java | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/OsmAnd/src/net/osmand/plus/wikivoyage/explore/ExploreTabFragment.java b/OsmAnd/src/net/osmand/plus/wikivoyage/explore/ExploreTabFragment.java index 630f2b9e2c..4bd39e481f 100644 --- a/OsmAnd/src/net/osmand/plus/wikivoyage/explore/ExploreTabFragment.java +++ b/OsmAnd/src/net/osmand/plus/wikivoyage/explore/ExploreTabFragment.java @@ -110,7 +110,9 @@ public class ExploreTabFragment extends BaseOsmAndFragment implements DownloadIn downloadIndexesRequested = false; indexItem = getMyApplication().getDownloadThread().getIndexes() .getWikivoyageItem(getWikivoyageFileName()); - addDownloadUpdateCard(false); + if(downloadUpdateCard == null) { + addDownloadUpdateCard(false); + } } } @@ -123,7 +125,6 @@ public class ExploreTabFragment extends BaseOsmAndFragment implements DownloadIn && indexItem != null && current == indexItem && (!current.isDownloaded() || current.isOutdated())) { - addDownloadUpdateCard(true); downloadUpdateCard.setProgress(downloadThread.getCurrentDownloadingItemProgress()); adapter.updateDownloadUpdateCard(); } @@ -139,9 +140,9 @@ public class ExploreTabFragment extends BaseOsmAndFragment implements DownloadIn } private void addDownloadUpdateCard(boolean loadingInProgress) { - if(downloadUpdateCard != null) { - return; - } +// if(downloadUpdateCard != null) { +// return; +// } final OsmandApplication app = getMyApplication(); boolean outdated = indexItem != null && indexItem.isOutdated();