From a2c2b9a163cb7190aa70ec3c342c5ef4afe2638c Mon Sep 17 00:00:00 2001 From: Christian Pointner Date: Sun, 29 Dec 2013 18:06:54 +0000 Subject: rehiding visibox fixing add new marker? --- map3.js | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'map3.js') diff --git a/map3.js b/map3.js index 0f840a4..f07829f 100644 --- a/map3.js +++ b/map3.js @@ -19,6 +19,7 @@ debug = function (log_txt) { } function initialize(lat, lng, res) { + $('#visibox').hide(); $('#southeastcontainer').hide(); debug("Initializing Funkfeuer Graz Map"); @@ -92,8 +93,6 @@ function onAddOverlay(overlay) { function onMapClick(overlay, point) { - debug("onMapClick called!"); - if(!overlay) { map.setCenter(point); setNewMarker(point); @@ -568,13 +567,14 @@ function setNewMarker(point) { map.addOverlay(marker); marker.openInfoWindowHtml(addNewNodeText(point)); */ - var marker = new GMarker(point,makeIcon('newnode')); - google.maps.event.addListener(marker,"infowindowclose",function () { - map.removeOverlay(marker); - }); - map.addOverlay(marker); - marker.openInfoWindowHtml(addNewNodeText(point)); + + var marker = new google.maps.Marker({position: point, icon: makeIcon('newnode')}); + // google.maps.event.addListener(marker,"infowindowclose",function () { + // map.removeOverlay(marker); + // }); + marker.setMap(map); + marker.openInfoWindowHtml(addNewNodeText(point)); } function fflogin(username, password) { -- cgit v1.2.1