I am totally new to google's maps api for android and I was wondering if it is possible to restrict the area the map is showing to one country only. I mean my target users are in my own country only and it is not useful nor logical to show them the whole world when the application logic is going to be only on this country.
Any ideas?
ps: if it is not possible in google's api,is there a way to do this with another api form another source which provides a mapping service?
If you are still interested, now it's possible to restrict the user's panning to a given area using the setLatLngBoundsForCameraTarget
method.
You will need to update the dependencies for your Play Services:
dependencies {
compile 'com.google.android.gms:play-services:9.6.1'
}
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