It’s hard for me to figure out how to properly handle a resolution-changing user while my application is still running in the background.
In my application, I have a location class that registers location changes and when the location changes status it is sent to the server. However, this works in the background.
When my application is running, I test it with the user, if I use it to use location services, and if so, I continue to configure this class. However, the user can use my application and enter the settings and delete this permission. I can and will definitely check if it is allowed in my location class before requesting a location from the location service to avoid a crash. However, I don’t do business when the place comes, so I’m not sure how to tell them that my application needs location services.
EDIT:
It seems that android is restarting your application if permission has been revoked in the settings. However, I confirmed that at the moment, the android does not restart your application if permission was granted using the settings.
source share