Skip to content
Snippets Groups Projects
Commit c73c44c4 authored by hadim's avatar hadim Committed by haiiro.simeji
Browse files

Issue #1565792: MarkerClusterer is not working

parent acde2573
No related branches found
No related tags found
No related merge requests found
......@@ -8,8 +8,8 @@
/*global Drupal, GMarker, MarkerClusterer */
// Replace to override marker creation
Drupal.gmap.factory.marker = function (loc, opts) {
return new GMarker(loc, opts);
Drupal.gmap.factory.marker = function (opts) {
return new google.maps.Marker(opts);
};
Drupal.gmap.addHandler('gmap', function (elem) {
......@@ -17,7 +17,10 @@ Drupal.gmap.addHandler('gmap', function (elem) {
obj.bind('init', function () {
// Set up the markermanager.
obj.mc = new MarkerClusterer(obj.map, [], Drupal.settings.gmap_markermanager);
obj.mc = new MarkerClusterer(obj.map, [], {
maxZoom: parseInt(Drupal.settings.gmap_markermanager["maxZoom"]),
gridSize: parseInt(Drupal.settings.gmap_markermanager["gridSize"])
});
});
obj.bind('addmarker', function (marker) {
// @@@ Would be really nice to have bulk adding support in gmap.
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment