From 43efb357db3c308e6dca46daf1ee605fe9919d80 Mon Sep 17 00:00:00 2001 From: sonora Date: Fri, 2 Jan 2015 23:51:46 +0100 Subject: [PATCH] consolidate a few lines --- .../osmand/plus/dashboard/DashFavoritesFragment.java | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/OsmAnd/src/net/osmand/plus/dashboard/DashFavoritesFragment.java b/OsmAnd/src/net/osmand/plus/dashboard/DashFavoritesFragment.java index 93bf019e6c..c4283cf95e 100644 --- a/OsmAnd/src/net/osmand/plus/dashboard/DashFavoritesFragment.java +++ b/OsmAnd/src/net/osmand/plus/dashboard/DashFavoritesFragment.java @@ -175,15 +175,13 @@ public class DashFavoritesFragment extends DashBaseFragment { } public void updateLocation(Location location) { - //if (location == null) { - // return; - //} if (location != null) { - this.location = location; + //this.location = location; loc = new LatLon(location.getLatitude(), location.getLongitude()); - } - if (loc == null) { + } else if (getMyApplication().getSettings().getLastKnownMapLocation() != null) { loc = getMyApplication().getSettings().getLastKnownMapLocation(); + } else { + return; } this.loc = loc; updateArrows();