From 387c7dd61707f90f47c9b515b52adab330455d98 Mon Sep 17 00:00:00 2001 From: Alex Zolotarev Date: Mon, 13 Feb 2012 06:42:56 +0300 Subject: [PATCH] [android] Do not filter too old last known location - to be closer to GMaps behavior --- .../src/com/mapswithme/maps/location/LocationService.java | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/android/src/com/mapswithme/maps/location/LocationService.java b/android/src/com/mapswithme/maps/location/LocationService.java index 047bcabc1a..02c7917b3d 100644 --- a/android/src/com/mapswithme/maps/location/LocationService.java +++ b/android/src/com/mapswithme/maps/location/LocationService.java @@ -189,9 +189,9 @@ public class LocationService implements LocationListener, SensorEventListener, W // @param currentBestLocation The current Location fix, to which you want to compare the new one protected boolean isBetterLocation(Location newLocation, Location currentBestLocation) { - // A new location is thrown away if it's too old - if (java.lang.System.currentTimeMillis() - newLocation.getTime() > TWO_MINUTES) - return false; +// // A new location is thrown away if it's too old +// if (java.lang.System.currentTimeMillis() - newLocation.getTime() > TWO_MINUTES) +// return false; // A new location is better than no location if (currentBestLocation == null)