Back to project page NVS.
The source code is released under:
Apache License
If you think the Android project NVS listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package com.jmuenster.gps; /*from w w w. j a v a2s . c om*/ import android.location.Location; import android.location.LocationListener; import android.os.Bundle; import com.google.android.maps.GeoPoint; import com.google.android.maps.MapView; public class MyLocationListener implements LocationListener { private MapView mv; public MyLocationListener (MapView mv) { this.mv = mv; } public void onLocationChanged(Location loc) { mv.getController().animateTo(new GeoPoint((int)(loc.getLatitude()*1E6), (int)(loc.getLongitude()*1E6))); } public void onProviderDisabled(String provider) { // TODO Auto-generated method stub } public void onProviderEnabled(String provider) { // TODO Auto-generated method stub } public void onStatusChanged(String provider, int status, Bundle extras) { // TODO Auto-generated method stub } }