mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-11-01 15:23:54 +01:00
LocationPickerActivity.java: replace code with a method call
Before this change, there was several lines of code which moved the map center to the EXIF location. After this change, the several lines of code have been replaced with a simpler method call which produces the same result.
This commit is contained in:
parent
e55f4916ee
commit
47eaff429a
1 changed files with 2 additions and 7 deletions
|
|
@ -358,12 +358,7 @@ public class LocationPickerActivity extends BaseActivity implements
|
|||
smallToolbarText.setText(getResources().getString(R.string.pan_and_zoom_to_adjust));
|
||||
fabCenterOnLocation.setVisibility(View.VISIBLE);
|
||||
removeSelectedLocationMarker();
|
||||
if (cameraPosition != null && mapView != null) {
|
||||
if (mapView.getController() != null) {
|
||||
mapView.getController().animateTo(new GeoPoint(cameraPosition.getLatitude(),
|
||||
cameraPosition.getLongitude()));
|
||||
}
|
||||
}
|
||||
moveMapToMediaLocation();
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -401,7 +396,7 @@ public class LocationPickerActivity extends BaseActivity implements
|
|||
*/
|
||||
private void showInMapApp() {
|
||||
fr.free.nrw.commons.location.LatLng position = null;
|
||||
|
||||
|
||||
if(activity.equals("UploadActivity") && cameraPosition != null){
|
||||
//EXIF location data is available
|
||||
position = new fr.free.nrw.commons.location.LatLng(cameraPosition.getLatitude(),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue