Fixing Geolocation so it grabs data from the network faster

This commit is contained in:
Joe Bowser
2009-12-15 15:16:35 -08:00
parent 3898130a30
commit 9276729be5
3 changed files with 8 additions and 4 deletions
+4 -2
View File
@@ -15,6 +15,7 @@ public class GeoBroker {
private WebView mAppView;
private Context mCtx;
private HashMap<String, GeoListener> geoListeners;
private GeoListener listener;
public GeoBroker(WebView view, Context ctx)
{
@@ -23,8 +24,9 @@ public class GeoBroker {
}
public void getCurrentLocation()
{
GeoListener listener = new GeoListener("global", mCtx, 10000, mAppView);
{
if (listener == null)
listener = new GeoListener("global", mCtx, 10000, mAppView);
}
public String start(int freq, String key)