9

Getting a location in android is so complicated:
First there's the permissions. Ok add it to the manifest. Oh wait, run-time permissions.
Gotta check if user has allowed the specific app to use location or ask for the permission.
Ok. That's done. Why am i not getting a location? Of course, user can turn it off from settings. Gotta check for that aswell. Or ask for it somehow.
Finally i should be able to get the location! Now, how to I use the Location service to get location in the most efficient way that suits for me? Or should I use the Google api.
Every answer in stackoverflow uses a different method. Oh well, gotta try out them all :).

Comments
  • 2
    As an sort of battle proofen Android dev: go with the Google APIs since they also use Wi-Fi SSIDs to determine ones location - which is pretty much the only reliable and accurate method in big cities. If you want to spare yourself the dance with the Google API Client you can use https://github.com/patloew/...
  • 2
    Ugh..not the runtime permissions!
Add Comment