p-lr / MapView

A Fast, memory efficient Android library to display tiled maps, with support for markers, paths, and rotation.
Apache License 2.0
184 stars 38 forks source link

Displaying multiple maps #14

Closed c0dd3vi11 closed 4 years ago

c0dd3vi11 commented 4 years ago

Hello, @peterLaurence! Could you help me how to manage maps switching with your MapView? redrawTiles seems to work not correct.

I tried to make three different MapView's. But then I got a problem that sometimes tiles don't draw when I change visibility from View.INVISIBLE to View.VISIBLE for a next MapView.

p-lr commented 4 years ago

Hi,

The recommended way to switch maps is to destroy the existing MapView using MapView.destroy(), remove it from the view hierarchy, and then create a new MapView and configure it. This is how it it's intended to be used.

c0dd3vi11 commented 4 years ago

Thank you for replying. I got it.