From 55a377cb477218322fda4d8194906525b6879c98 Mon Sep 17 00:00:00 2001 From: vshcherb Date: Fri, 19 Jun 2020 15:10:12 +0200 Subject: [PATCH] Don't ask permission --- .../osmand/plus/activities/MapActivityActions.java | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/OsmAnd/src/net/osmand/plus/activities/MapActivityActions.java b/OsmAnd/src/net/osmand/plus/activities/MapActivityActions.java index b9cb45d600..25c1b95601 100644 --- a/OsmAnd/src/net/osmand/plus/activities/MapActivityActions.java +++ b/OsmAnd/src/net/osmand/plus/activities/MapActivityActions.java @@ -466,13 +466,13 @@ public class MapActivityActions implements DialogProvider { } else if (standardId == R.string.context_menu_item_search) { mapActivity.showQuickSearch(latitude, longitude); } else if (standardId == R.string.context_menu_item_directions_from) { - if (OsmAndLocationProvider.isLocationPermissionAvailable(mapActivity)) { + //if (OsmAndLocationProvider.isLocationPermissionAvailable(mapActivity)) { enterDirectionsFromPoint(latitude, longitude); - } else { - ActivityCompat.requestPermissions(mapActivity, - new String[]{Manifest.permission.ACCESS_FINE_LOCATION}, - REQUEST_LOCATION_FOR_DIRECTIONS_NAVIGATION_PERMISSION); - } + //} else { + // ActivityCompat.requestPermissions(mapActivity, + // new String[]{Manifest.permission.ACCESS_FINE_LOCATION}, + // REQUEST_LOCATION_FOR_DIRECTIONS_NAVIGATION_PERMISSION); + //} } else if (standardId == R.string.measurement_tool) { mapActivity.getContextMenu().close(); MeasurementToolFragment.showInstance(mapActivity.getSupportFragmentManager(), new LatLon(latitude, longitude)); @@ -1186,4 +1186,4 @@ public class MapActivityActions implements DialogProvider { }); } -} \ No newline at end of file +}