// JavaScript Document
function loadMainMap(objID,mapBox,long,lat,z) {
		mapInit(objID);
		standardControls();
		map.setCenter(new GLatLng(lat,long), z);
		if ( places.length > 0 ) {
			processLocs(places);
			//rebound();
		}
}

function loadShowcaseMap(objID,mapBox,long,lat,z) {
	mapInit(objID);
	standardControls();
	vpoint = new GLatLng(long,lat);
	map.setCenter(vpoint, 11);
	if ( places.length > 0 ) {
		processAddressList(places);
	}
}

/*function loadDetailPageMap(objID,mapBox,long,lat,z) {
	mapInit(objID);
	standardControls();
	map.setCenter(new GLatLng(lat,long), 15);
	if ( places.length > 0 ) {
		processAddress(places);
	}
	streetView2(places2);
	
}*/

function loadDetailPageMap(objID,mapBox,long,lat,z) {
	
	if(mapExists) {
	
		mapInit(objID);
		standardControls();
		map.setCenter(new GLatLng(lat,long), 15);
		if ( places.length > 0 ) {
			processAddress2(places,mapViewLat,mapViewLong);
		}
		streetView(mapViewLat,mapViewLong);
		
	} else {
		/*var obj = document.getElementById(objID);
		var divContainer = document.getElementById('divStreetViewPanorama');
		var mapMessage = document.getElementById('mapMessage');
		
		obj.innerHTML = '<p><strong>The exact location could not be found.</strong></p>';
		divContainer.innerHTML = '';
		mapMessage.innerHTML = '';
		
		obj.style.height = '30px';
		divContainer.style.display = 'none';
		mapMessage.style.display = 'none';*/
		mapInit(objID);
		standardControls();
		map.setCenter(new GLatLng(lat,long), 15);
		if ( places.length > 0 ) {
			processAddress(places);
		}
		if ( places.length > 0 ) {
		streetView2(places2);
		}
	}
}
