mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-26 20:33:53 +01:00
Add constant for request code
This commit is contained in:
parent
40a2e03b9c
commit
3bd1baaf8d
1 changed files with 2 additions and 1 deletions
|
|
@ -43,6 +43,7 @@ public class NearbyActivity extends NavigationBaseActivity {
|
|||
@BindView(R.id.progressBar)
|
||||
ProgressBar progressBar;
|
||||
private boolean isMapViewActive = false;
|
||||
private static final int LOCATION_REQUEST = 1;
|
||||
|
||||
private LocationServiceManager locationManager;
|
||||
private LatLng curLatLang;
|
||||
|
|
@ -100,7 +101,7 @@ public class NearbyActivity extends NavigationBaseActivity {
|
|||
if (ContextCompat.checkSelfPermission(this, Manifest.permission.ACCESS_FINE_LOCATION) != PackageManager.PERMISSION_GRANTED) {
|
||||
//Request permission and display notification that Nearby places cannot be shown without permission
|
||||
ActivityCompat.requestPermissions(this,
|
||||
new String[]{Manifest.permission.ACCESS_FINE_LOCATION}, 1);
|
||||
new String[]{Manifest.permission.ACCESS_FINE_LOCATION}, LOCATION_REQUEST);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue