From 71ab59e400700e8d8425a8c8f4967ee471749613 Mon Sep 17 00:00:00 2001 From: simon Date: Fri, 27 Nov 2020 16:46:03 +0200 Subject: [PATCH] bug fix --- OsmAnd/src/net/osmand/plus/mapcontextmenu/MenuBuilder.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/OsmAnd/src/net/osmand/plus/mapcontextmenu/MenuBuilder.java b/OsmAnd/src/net/osmand/plus/mapcontextmenu/MenuBuilder.java index a39259a9e4..c89789bc33 100644 --- a/OsmAnd/src/net/osmand/plus/mapcontextmenu/MenuBuilder.java +++ b/OsmAnd/src/net/osmand/plus/mapcontextmenu/MenuBuilder.java @@ -109,6 +109,7 @@ public class MenuBuilder { private String preferredMapAppLang; private boolean transliterateNames; private View view; + private View photoButton; private final OpenDBAPI openDBAPI = new OpenDBAPI(); private String[] placeId = new String[0]; @@ -121,6 +122,9 @@ public class MenuBuilder { @Override public void onPlaceIdAcquired(String[] placeId) { MenuBuilder.this.placeId = placeId; + if (placeId.length < 2){ + photoButton.setVisibility(View.GONE); + } } @Override @@ -404,6 +408,7 @@ public class MenuBuilder { }); //TODO This feature is under development view.setVisibility(View.GONE); + photoButton = view; return view; }