Missing map.controls...
Closed this issue · 1 comments
I am using latest gmap3 version (7.2.0) and I am trying to render custom control on map with code like the one below:
`
map = $('#map').gmap3({
center: { lat: -34.9284989, lng: 138.60074559999998 }, //This should be calculated from data
zoom: 15,
mapTypeId : google.maps.MapTypeId.ROADMAP,
mapTypeControl: false,
scaleControl: true,
streetViewControl: false
});
var hamburgerControlDiv = $('#hamburger').get(0);
hamburgerControlDiv.index = 1;
map.controls[google.maps.ControlPosition.TOP_LEFT].push(hamburgerControlDiv);
`
but I keep getting map.controls is undefined error. When I use debugger, I can see that there is no controls property on map.
Roaming around gmap3 forum, I found out couple of posts that are referring to use code like above, but these posts are for earlier gmap versions (4 or 5 if I recall correctly), so I was wondering on how to achive same thing with latest gmap version?
Thanks in advance
I found a solution via overlay