I am using android-maps-utils for clustering markers in a google's map.
I need to offer users the posibility of changing the zoom level clustering and to switch on and off the clustering animation.
Zoom level is managed inside NonHierarchicalDistanceBasedAlgorithm.java, I was able to change it dynamically but it only works when doing it inside
onCreate()
, because if I change it aftermClusterManager.setRenderer(new MyClusterRenderer(this, map, mClusterManager))
clustering becomes crazy. I need to be able to change it from insideonResume()
.Animation is set inside DefaultClusterRenderer.java, I have tried many things but the only way I was able to change the
SHOULD_ANIMATE
variable was by fetching a shared preference directly inside that class, so making it posible to change that only by refreshing the activity. Again, I want to do it from insideonResume()
or anyway that doens't involve refreshing the activity.