Issue
My mapview has a OnZoomListener which is called whenever the zoom changes. This works well for whenever the plus or minus buttons at the bottom are used to change the zoom. However, the listener is never called if the user uses pinch zooming in order to zoom in or out. Do you have any suggestions on how to make the pinch zoom actually call my listener? If not, do you have any idea how I can disable the pinch zoom for my mapview? Thanks.
Edit: My custom zoom listener is added like this:
ZoomButtonsController zoomButton = myMapView.getZoomButtonsController();
zoomButton.setOnZoomListener(listener);
Solution
the problem is that you are setting the listener to the zoom control and not to the map, thats why the pinch (that is a map event not a zoom control event) doesn't call the listener.
The only way to handle this events is to implement a custom map and a custom listener.
This link have the example and the code that you need.
Answered By - h0m3r16
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.