friend's I need help on pointing mapview findme location option,when i click find me from map it shows location without identificaton,after long time only the circle with pin point appears,but i need it to appear immediately,what can i do what the problem is. Here my code for findme click event...
try {
criteria = new Criteria();
criteria.setAccuracy(Criteria.ACCURACY_FINE);
criteria.setAltitudeRequired(false);
criteria.setBearingRequired(false);
criteria.setCostAllowed(true);
criteria
.setPowerRequirement(Criteria.POWER_LOW);
locationManager.requestLocationUpdates(
LocationManager.GPS_PROVIDER, 1000L,
500.0f, locationListener);
overlays = wv.getOverlays();
MyLocationOverlay myLocationOverlay = new MyLocationOverlay(
Bru_Maps_Result.this, wv);
overlays.add(myLocationOverlay);
myLocationOverlay.enableMyLocation();
String provider = locationManager.getBestProvider(criteria, true);
// Update the UI using the last known locations
Location location = locationManager.getLastKnownLocation(provider);
updateWithNewLocation(location);
Log.v("Find_Location",location.toString());
// Start listening for location changes
locationManager.requestLocationUpdates(
provider, 60000, // 1min
1000, // 1km
locationListener);
// geoPoint = currentlocation.getMyLocation();
// wv_cont.setCenter(geoPoint);
// wv_cont.setZoom(18);
} catch (Exception e) {
mToast = Toast.makeText(Bru_Maps_Result.this,
R.string.errorinmaps,
Toast.LENGTH_SHORT);
mToast.show();
Log.v(TAG, "exception current location : " + e);
}
Thanks in advance.