私のアプリケーションには、Google マップ ビューでユーザーに行き方を示すためのボタンがあります。
Google Now からユーザーの自宅/職場の場所を取得する方法はありますか?
私のアプリケーションには、Google マップ ビューでユーザーに行き方を示すためのボタンがあります。
Google Now からユーザーの自宅/職場の場所を取得する方法はありますか?
アプリケーションで Google Maps API を使用して、このような既存の方法で現在地を見つけることができます
LocationManager service = (LocationManager) getSystemService(LOCATION_SERVICE);
Criteria criteria = new Criteria();
String provider = service.getBestProvider(criteria, false);
Location location = service.getLastKnownLocation(provider);
LatLng userLocation = new LatLng(location.getLatitude(),location.getLongitude());