From 1ddf2775e1b9bdbd98b2a3c0e0e9ae0708ca57ae Mon Sep 17 00:00:00 2001 From: Victor Shcherb Date: Wed, 30 May 2018 14:53:53 +0200 Subject: [PATCH] Don't show points if there are no points --- .../wikivoyage/article/WikivoyageArticleDialogFragment.java | 3 +++ 1 file changed, 3 insertions(+) diff --git a/OsmAnd/src/net/osmand/plus/wikivoyage/article/WikivoyageArticleDialogFragment.java b/OsmAnd/src/net/osmand/plus/wikivoyage/article/WikivoyageArticleDialogFragment.java index 8f23e4d7cf..6f69d2c332 100644 --- a/OsmAnd/src/net/osmand/plus/wikivoyage/article/WikivoyageArticleDialogFragment.java +++ b/OsmAnd/src/net/osmand/plus/wikivoyage/article/WikivoyageArticleDialogFragment.java @@ -303,7 +303,10 @@ public class WikivoyageArticleDialogFragment extends WikiArticleBaseDialogFragme webViewClient.setArticle(article); articleToolbarText.setText(article.getTitle()); if (article.getGpxFile() != null && article.getGpxFile().getPointsSize() > 0) { + trackButton.setVisibility(View.VISIBLE); trackButton.setText(getString(R.string.shared_string_gpx_points) + " (" + article.getGpxFile().getPointsSize() + ")"); + } else { + trackButton.setVisibility(View.GONE); } TravelLocalDataHelper ldh = getMyApplication().getTravelDbHelper().getLocalDataHelper();