问题
I want to make an app, when user open my app user will get their current location in my app and while user change their location it will also update after some specific time. I got solution of changed location while user change their location but i need to show current location of user while user open my app.
回答1:
googleMap.setMyLocationEnabled(true);
Location myLocation = googleMap.getMyLocation();
These are the the key lines to get current location.
for more info ,refer these tutorials: android show current location on map using google maps api
and how to get current location in google map android
来源:https://stackoverflow.com/questions/42198041/how-to-show-current-location-of-user-while-open-my-app