

var redIcon = new GIcon();
redIcon.image = "../images/googlemaps/mm_20_3d_red.png";
redIcon.shadow = "";
redIcon.iconSize = new GSize(12, 20);
redIcon.shadowSize = new GSize(22, 20);
redIcon.iconAnchor = new GPoint(6, 20);
redIcon.infoWindowAnchor = new GPoint(5, 1);
redIcon.imageMap = [4,0,0,4,0,7,3,11,4,19,7,19,8,11,11,7,11,4,7,0]; 
redIcon.transparent = "../images/googlemaps/mm_20_transparent.png";

var greenIcon = new GIcon();
greenIcon.image = "../images/googlemaps/mm_20_3d_green.png";
greenIcon.shadow = "";
greenIcon.iconSize = new GSize(12, 20);
greenIcon.shadowSize = new GSize(22, 20);
greenIcon.iconAnchor = new GPoint(6, 20);
greenIcon.infoWindowAnchor = new GPoint(5, 1);
greenIcon.imageMap = [4,0,0,4,0,7,3,11,4,19,7,19,8,11,11,7,11,4,7,0]; 
greenIcon.transparent = "../images/googlemaps/mm_20_transparent.png";

var yellowIcon = new GIcon();
yellowIcon.image = "../images/googlemaps/mm_20_3d_yellow.png";
yellowIcon.shadow = "";
yellowIcon.iconSize = new GSize(12, 20);
yellowIcon.shadowSize = new GSize(22, 20);
yellowIcon.iconAnchor = new GPoint(6, 20);
yellowIcon.infoWindowAnchor = new GPoint(5, 1);
yellowIcon.imageMap = [4,0,0,4,0,7,3,11,4,19,7,19,8,11,11,7,11,4,7,0]; 
yellowIcon.transparent = "../images/googlemaps/mm_20_transparent.png";

var blueIcon = new GIcon();
blueIcon.image = "../images/googlemaps/mm_20_3d_blue.png";
blueIcon.shadow = "";
blueIcon.iconSize = new GSize(12, 20);
blueIcon.shadowSize = new GSize(22, 20);
blueIcon.iconAnchor = new GPoint(6, 20);
blueIcon.infoWindowAnchor = new GPoint(5, 1);
blueIcon.imageMap = [4,0,0,4,0,7,3,11,4,19,7,19,8,11,11,7,11,4,7,0]; 
blueIcon.transparent = "../images/googlemaps/mm_20_transparent.png";

var orangeIcon = new GIcon();
orangeIcon.image = "../images/googlemaps/mm_20_3d_orange.png";
orangeIcon.shadow = "";
orangeIcon.iconSize = new GSize(12, 20);
orangeIcon.shadowSize = new GSize(22, 20);
orangeIcon.iconAnchor = new GPoint(6, 20);
orangeIcon.infoWindowAnchor = new GPoint(5, 1);
orangeIcon.imageMap = [4,0,0,4,0,7,3,11,4,19,7,19,8,11,11,7,11,4,7,0]; 
orangeIcon.transparent = "../images/googlemaps/mm_20_transparent.png";

var purpleIcon = new GIcon();
purpleIcon.image = "../images/googlemaps/mm_20_3d_purple.png";
purpleIcon.shadow = "";
purpleIcon.iconSize = new GSize(12, 20);
purpleIcon.shadowSize = new GSize(22, 20);
purpleIcon.iconAnchor = new GPoint(6, 20);
purpleIcon.infoWindowAnchor = new GPoint(5, 1);
purpleIcon.imageMap = [4,0,0,4,0,7,3,11,4,19,7,19,8,11,11,7,11,4,7,0]; 
purpleIcon.transparent = "../images/googlemaps/mm_20_transparent.png";




//	var map;
//	var intShowMarkers = 0;
//  var batch = [];	
//    function load(startLat,startLng,startZoom) {
//      if (GBrowserIsCompatible()) {
//        map = new GMap2(document.getElementById("mapWeather"));
////        map.setCenter(new GLatLng(-0.7,35), 5, G_HYBRID_MAP);
////        map.setCenter(new GLatLng(-1.29,36.85), 7, G_HYBRID_MAP);
//        map.setCenter(new GLatLng(startLat,startLng), startZoom, G_HYBRID_MAP);
//		map.addControl(new GSmallZoomControl());
////		map.addControl(new GScaleControl());
////		map.addControl(new GMapTypeControl());
////		var omap = new GOverviewMapControl(); 
////		map.addControl(omap); 
////		omap.hide(true); 
//		getMarkers();
//		window.setTimeout(setupMarkers, 0);
//      }
//    }



function getMarkers(n) {
	batch = [];
  var marker;

marker = new GMarker(new GLatLng(52.308334, 4.768056), {icon:yellowIcon, title:'Amsterdam-Schiphol Airport (AMS, Amsterdam)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('AMS');});
batch.push(marker);
marker = new GMarker(new GLatLng(50.90167, 4.494167), {icon:yellowIcon, title:'National Airport (BRU, Brussel)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('BRU');});
batch.push(marker);
marker = new GMarker(new GLatLng(51.47139, -0.452778), {icon:yellowIcon, title:'Heathrow Airport (LHR, Londen)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('LHR');});
batch.push(marker);
marker = new GMarker(new GLatLng(51.148056, -0.196667), {icon:yellowIcon, title:'Gatwick Airport (LGW, Londen)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('LGW');});
batch.push(marker);
marker = new GMarker(new GLatLng(49.009724, 2.548611), {icon:yellowIcon, title:'Charles De Gaulle Airport (CDG, Parijs)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('CDG');});
batch.push(marker);
marker = new GMarker(new GLatLng(50.03889, 8.570556), {icon:yellowIcon, title:'Frankfurt International Airport (FRA, Frankfurt)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('FRA');});
batch.push(marker);
marker = new GMarker(new GLatLng(51.281113, 6.752778), {icon:yellowIcon, title:'Dusseldorf Airport (DUS, Dusseldorf)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('DUS');});
batch.push(marker);

  return batch;
}




function getMarkers2(n) {
	batch2 = [];
  var marker;

marker = new GMarker(new GLatLng(-1.316667, 36.930832), {icon:yellowIcon, title:'Jomo Kenyatta International Airport (NBO, Nairobi)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('NBO');});
batch2.push(marker);
marker = new GMarker(new GLatLng(-4.031389, 39.593056), {icon:yellowIcon, title:'Moi International Airport (MBA, Mombasa)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('MBA');});
batch2.push(marker);
marker = new GMarker(new GLatLng(-3.226111, 40.100555), {icon:yellowIcon, title:'Malindi Airport (MYD, Malindi)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('MYD');});
batch2.push(marker);
marker = new GMarker(new GLatLng(-2.25, 40.911667), {icon:yellowIcon, title:'Lamu Airport (LAU, Lamu)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('LAU');});
batch2.push(marker);
marker = new GMarker(new GLatLng(-0.085556, 34.72861), {icon:yellowIcon, title:'Kisumu Airport (KIS, Kisumu)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('KIS');});
batch2.push(marker);

marker = new GMarker(new GLatLng(-3.433333, 37.066666), {icon:yellowIcon, title:'Kilimanjaro Airport (JRO, Arusha)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('JRO');});
batch2.push(marker);
marker = new GMarker(new GLatLng(-6.875278, 39.201942), {icon:yellowIcon, title:'Julius Nyerere International Airport (DAR, Dar Es Salaam)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('DAR');});
batch2.push(marker);
marker = new GMarker(new GLatLng(-4.885, 29.67), {icon:yellowIcon, title:'Kigoma Airport (TKQ, Kigoma)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('TKQ');});
batch2.push(marker);
marker = new GMarker(new GLatLng(-6.219167, 39.221943), {icon:yellowIcon, title:'Kisauni Airport (ZNZ, Zanzibar)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('ZNZ');});
batch2.push(marker);

marker = new GMarker(new GLatLng(0.0425, 32.438057), {icon:yellowIcon, title:'Entebbe Airport (EBB, Kampala)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('EBB');});
batch2.push(marker);

marker = new GMarker(new GLatLng(-1.967778, 30.14), {icon:yellowIcon, title:'Kigali International Airport (KGL, Kigali)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('KGL');});
batch2.push(marker);
marker = new GMarker(new GLatLng(-2.466667, 28.916668), {icon:yellowIcon, title:'Kamembe Airport (KME, Kamembe)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('KME');});
batch2.push(marker);
marker = new GMarker(new GLatLng(-1.683333, 29.25), {icon:yellowIcon, title:'Gisenyi Airport (GYI, Gisenyi)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('GYI');});
batch2.push(marker);

marker = new GMarker(new GLatLng(-3.383333, 29.366667), {icon:yellowIcon, title:'Bujumbura International Airport (BJM, Bujumbura)'} );
GEvent.addListener(marker, "click", function() {return setLuchthaven('BJM');});
batch2.push(marker);


  return batch2;
}

function setLuchthaven(strCode) {
//alert(strCode);
//window.open("http://opsafari.nl/extern/connext.asp?url=http%3A//www.flightstats.com/go/Airport/airportDetails.do%3FairportCode%3D"+strCode);
window.location=("http://opsafari.nl/extern/luchthavens.asp#"+strCode);
return true;

};

function setupMarkers() {
//  mgr = new GMarkerManager(map, {borderPadding: 16});
//  mgr.addMarkers(getMarkers(2), 3);
//  mgr.addMarkers(getMarkers(20), 6);
//  mgr.addMarkers(getMarkers(50), 8);
//  mgr.refresh();
if (intShowMarkers == 0) {

for (var i=0;i<batch.length;i++) {
         map.addOverlay(batch[i]);
}
intShowMarkers = 1;
}
};

function clearMarkers() {
//  mgr = new GMarkerManager(map, {borderPadding: 16});
//  mgr.addMarkers(getMarkers(2), 3);
//  mgr.addMarkers(getMarkers(20), 6);
//  mgr.addMarkers(getMarkers(50), 8);
//  mgr.refresh();
//getMarkers();
if (intShowMarkers == 1) {

for (var i=0;i<batch.length;i++) {
         map.removeOverlay(batch[i]);
}
intShowMarkers = 0;
}
};

function setupMarkers2() {
//  mgr = new GMarkerManager(map, {borderPadding: 16});
//  mgr.addMarkers(getMarkers(2), 3);
//  mgr.addMarkers(getMarkers(20), 6);
//  mgr.addMarkers(getMarkers(50), 8);
//  mgr.refresh();
if (intShowMarkers2 == 0) {

for (var i=0;i<batch2.length;i++) {
         map2.addOverlay(batch2[i]);
}
intShowMarkers2 = 1;
}
};

function clearMarkers2() {
//  mgr = new GMarkerManager(map, {borderPadding: 16});
//  mgr.addMarkers(getMarkers(2), 3);
//  mgr.addMarkers(getMarkers(20), 6);
//  mgr.addMarkers(getMarkers(50), 8);
//  mgr.refresh();
//getMarkers();
if (intShowMarkers2 == 1) {

for (var i=0;i<batch2.length;i++) {
         map2.removeOverlay(batch2[i]);
}
intShowMarkers2 = 0;
}
};