Bug fix: Markers disappears if zoom >= 17.5 (issue
MODIFY
plugin.xml
plugin.xml
<?xml version='1.0' encoding='utf-8'?>
-<plugin id="cordova-plugin-googlemaps" version="cluster-20170822-1656" xmlns="http://apache.org/cordova/ns/plugins/1.0" xmlns:android="http://schemas.android.com/apk/res/android">
+<plugin id="cordova-plugin-googlemaps" version="cluster-20170822-2333" xmlns="http://apache.org/cordova/ns/plugins/1.0" xmlns:android="http://schemas.android.com/apk/res/android">
<name>cordova-plugin-googlemaps</name>
<js-module name="BaseClass" src="www/BaseClass.js">
<runs />

MODIFY
www/Map.js
www/Map.js
@@ -1014,7 +1014,7 @@ Map.prototype.addMarkerCluster = function(markerClusterOptions, callback) {
var markerCluster = new MarkerCluster(self, result.id, {
"icons": markerClusterOptions.icons,
"markerMap": markerMap,
- "maxZoomLevel": Math.max(markerClusterOptions.maxZoomLevel, 18) || 15,
+ "maxZoomLevel": Math.min(markerClusterOptions.maxZoomLevel || 15, 18),
"debug": markerClusterOptions.debug === true
}, exec);
markerCluster.one("remove", function() {

MODIFY
www/MarkerCluster.js
www/MarkerCluster.js
@@ -407,7 +407,7 @@ MarkerCluster.prototype._redraw = function(params) {
prevResolution = self.get("resolution");
- currentZoomLevel = Math.round(currentZoomLevel < 0 ? 0 : currentZoomLevel);
+ currentZoomLevel = currentZoomLevel < 0 ? 0 : currentZoomLevel;
self.set("zoom", currentZoomLevel);
var resolution = 1;
@@ -960,7 +960,13 @@ MarkerCluster.prototype._redraw = function(params) {
"new_or_update": new_or_update_clusters,
"delete": delete_clusters
}], {sync: true});
-
+/*
+ console.log({
+ "resolution": resolution,
+ "new_or_update": new_or_update_clusters,
+ "delete": delete_clusters
+ });
+*/
};
MarkerCluster.prototype.getClusterIcon = function(cluster) {

Bug fix: Markers disappears if zoom >= 17.5 (issue #20)