var myVenues = new Array();

function load() {
	
  if (GBrowserIsCompatible()) {
    map = new GMap2(document.getElementById("map"));

    map.addControl(new GSmallMapControl());
    //map.addControl(new GMapTypeControl());
    map.addControl(new GScaleControl());
    map.addControl(new GOverviewMapControl());

     map.setCenter(new GLatLng(10.66, -61.45), 11);

  }
}

function showMarker(point, color, msg, venueid) {

   var marker = new GMarker(point, {icon: getIcon(color)});

   map.addOverlay(marker);

   GEvent.addListener(marker, 'mouseover', function() {

     marker.openInfoWindowHtml(msg);
   });
   GEvent.addListener(marker, 'mouseout', function() {

     map.closeInfoWindow();
   });
   GEvent.addListener(marker, 'click', function() {

     location.href = defaultURL;
   });
}

function getIcon(color) { 
  var icon = new GIcon(G_DEFAULT_ICON, 'restaurants/images/markers/marker_hex.png'); 
  icon.shadow = 'restaurants/images/markers/sign_shadow.png';
  icon.iconSize = new GSize(28, 28);
  icon.shadowSize = new GSize(42, 28); 
  return icon; 
} 

function createVenue(venueid, latitude, longtitude, msg, colour) {
  this.venueid  = venueid
  this.latitude  = latitude;
  this.longtitude = longtitude;
  this.msg = msg;
  this.colour = colour;
}


