mirror of
https://github.com/commons-app/apps-android-commons.git
synced 2025-10-26 12:23:58 +01:00
Optimize FileProcessor
This commit is contained in:
parent
be5c05435e
commit
4a5257c2c7
2 changed files with 3 additions and 5 deletions
|
|
@ -119,7 +119,7 @@ public class FileProcessor implements SimilarImageDialogFragment.onResponse {
|
|||
if (decimalCoords == null || !imageObj.imageCoordsExists) {
|
||||
//Find other photos taken around the same time which has gps coordinates
|
||||
if (!haveCheckedForOtherImages)
|
||||
findOtherImages(gpsEnabled);// Do not do repeat the process
|
||||
findOtherImages();// Do not do repeat the process
|
||||
} else {
|
||||
useImageCoords();
|
||||
}
|
||||
|
|
@ -137,9 +137,8 @@ public class FileProcessor implements SimilarImageDialogFragment.onResponse {
|
|||
/**
|
||||
* Find other images around the same location that were taken within the last 20 sec
|
||||
*
|
||||
* @param gpsEnabled True if GPS is enabled
|
||||
*/
|
||||
private void findOtherImages(boolean gpsEnabled) {
|
||||
private void findOtherImages() {
|
||||
Timber.d("filePath" + getPathOfMediaOrCopy());
|
||||
|
||||
long timeOfCreation = new File(filePath).lastModified();//Time when the original image was created
|
||||
|
|
|
|||
|
|
@ -1,6 +1,5 @@
|
|||
package fr.free.nrw.commons.upload;
|
||||
|
||||
import android.content.SharedPreferences;
|
||||
import android.media.ExifInterface;
|
||||
import android.support.annotation.NonNull;
|
||||
import android.support.annotation.Nullable;
|
||||
|
|
@ -16,7 +15,7 @@ import timber.log.Timber;
|
|||
* is uploaded, extract latitude and longitude from EXIF data of image.
|
||||
*/
|
||||
public class GPSExtractor {
|
||||
|
||||
|
||||
private ExifInterface exif;
|
||||
private double decLatitude;
|
||||
private double decLongitude;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue