在Android中获取用户GPS位置的最佳方法
locationrequest = LocationRequest.create(); locationrequest.setInterval(10000); locationclient.requestLocationUpdates(locationrequest,new com.google.android.gms.location.LocationListener() { @Override public void onLocationChanged(Location location) { Log.i(TAG, "Last Known Location :" + location.getLatitude() + "," + location.getLongitude()); } });
相关分类