0
I’m using the Cameraposition() to get Camera Zoom on Google Maps
mMap.getCameraPosition().zoom
It works perfectly when I call somewhere in the code, but I would like to create a Listener (Listener) for changing the Camera Zoom either by gestures or clicks on the [+] and [-] Zoom button, and get the new Zoom value every time it is changed by the user, I found this beautiful example, but the GoogleMap.OnCameraChangeListener
of the example is obsolete according to its documentation
The documentation that I quoted myself from which new methods I should use, but no practical example, it seems that the GoogleMap.OnCameraChangeListener
was divided into Googlemap.Oncameramovestartedlistener, Googlemap.Oncameramovelistener and Googlemap.Oncameraidlelistener, as I have never worked with Google Maps event listeners it was very confusing for me to use them only with this documentation information.
Someone has a simple and practical example using the new Methods to listen to Camera changes (Zoom)?
It can be more of a Listener since by gestures I believe it will be one and by the buttons will be another...
What’s the problem with Oncameraidlelistener? It rotates when the camera finishes moving. That’s not what you want?
– Pablo Almeida
@Pabloalmeida no problem, if the
OnCameraIdleListener
is called when the Zoom is changed, just need a practical example of how to use it, I have not found any example to test of the 3 methods I quoted, if you have an example of how to use it, will this answering my question.– Chinnon Santos