... 지금까지, 너무 좋아 ... 그것은 않습니다 내 위치가 제대로GPS 위치를 자주 업데이트하는 방법은 무엇입니까? 나는 구글지도에 위치를 표시하는 응용 프로그램을 쓰고 있어요
문제는이 GPS가 업데이트되지 않는 것입니다 내가 이동하고있는 경우이다 (또는,하지만 시간이 지나면 만)
누구나 네이티브 Google지도 (안드로이드)와 같은 방식으로이 작업을 수행하는 방법을 알고 있습니까? 당신은 '내 위치'당신이 이동 변경 깜박이는 파란색 점을 보여주고 클릭하면 이
이
내 코드는 ...입니다 ://Initializing the listeners
locationManager.requestLocationUpdates(LocationManager.NETWORK_PROVIDER, 35000, 10, networkLocationListener);
locationManager.requestLocationUpdates(LocationManager.GPS_PROVIDER, 35000, 10, gpsLocationListener);
//and now, in both 'networkLocationListener' and 'gpsLocationListener'
//I overwrite the method 'onLocationChanged':
@Override
public void onLocationChanged(Location location) {
Log.i("test", "New network location: "+location.getLatitude()+
" , "+location.getLongitude());
myLongitude= location.getLongitude();
myLatitude= location.getLatitude();
}
//and the variables myLongitude and myLatitude are the only ones that I need to display my
//position in the map...
내가 뭔가를 놓친 경우 누군가가 알고 있습니까 ?