I tried to put the user agent (cf https://github.com/osmdroid/osmdroid/wiki/Important-notes-on-using-osmdroid-in-your-app), but when I put the line OpenStreetMapTileProviderConstants.setUserAgentValue(BuildConfig.APPLICATION_ID);
Android studio is telling me that setUserAgentValue is depreciated.
What can I do to solve that ? For now when I run the app I have a grid with no map.
Thanks you very much in advance !
It's deprecated because it's been moved to another location which consolidates all configuration settings for osmdroid. Try the following
Configuration.getInstance().setUserAgentValue(...)
The older method was rewritten to wire it into the new configuration construct.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With