/*

V2 - DEFASADA

function loadCityMap( w, h, ll, lg, zoom ){
	
	//alert( "loadMapCity" );
	var map;
	
	map = null;
	
	if( GBrowserIsCompatible() ){
	
		//alert( "isCompatible" );
		
		//alert( "ll= "+ ll +" / lg= " + lg + "/ zoom= " + zoom );

		map = new GMap2( document.getElementById( "canvasMap" ), { size: new GSize( w, h ) } );
		map.setCenter( new GLatLng( ll, lg ), zoom );
		//map.addControl( new GSmallZoomControl() );
		map.setMapType( G_NORMAL_MAP );
		
		var point = new GPoint( lg - 0.08, ll - 0.03 );
	
		var icone = new GIcon( G_DEFAULT_ICON );
		icone.image = "../imgs/googlemaps_icon.png";
		icone.shadow = "../imgs/googlemaps_icon_shadow.png";
		icone.iconSize = new GSize( 30, 32 );
		icone.shadowSize = new GSize( 47, 32 );
		markerOptions = { icon:icone };
	
		map.addOverlay( new GMarker( point, markerOptions ) );
	}
	
	map = null;
	
}
*/

/* V3 */

var GMAPS3_LL = GMAPS3_LG = GMAPS3_Z = 0;

function gmaps3_configura( ll, lg, z ){
	
	GMAPS3_LL = ll;
	GMAPS3_LG = lg;
	GMAPS3_Z  = z;
	
}

function gmaps3_inicia(){
	
	var lats = new google.maps.LatLng( GMAPS3_LL, GMAPS3_LG );
    var op = { zoom: GMAPS3_Z, center: lats, mapTypeId: google.maps.MapTypeId.ROADMAP }
    var map = new google.maps.Map( document.getElementById("canvasMap"), op );
  	var mark = new google.maps.Marker( { position: lats, map: map, icon: "../imgs/googlemaps_icon.png", shadow: "../imgs/googlemaps_icon_shadow.png" } );
	
}

function gmaps3_carregaScript(){
	
	var script = document.createElement( "script" );
	
	script.type = "text/javascript";
	script.src = "http://maps.google.com/maps/api/js?sensor=false&callback=gmaps3_inicia";
	
	document.body.appendChild( script );
	
}
