
function animate_content()
{
	$('.content_container .content').animate({
        marginRight: "5%",
		opacity: 0	
      }, 1, function()
      {
    	  $('.content_container .content div#contact_us').css("opacity", "1");
    	  $('.content_container .content img').css("opacity", "1");
    	  $('.content_container .content .actual_content').css("opacity", "1");
    	  $('.content_container .content #mu_location').css("opacity", "1");
    	  $('.content_container .content .jcarousel-skin-tango').css("opacity", "1");
    	  $('.content_container .content .jcarousel-next-vertical').css("opacity", "1");
    	  $('.content_container .content .jcarousel-prev-vertical').css("opacity", "1");
    	  
      } );

	$('.content_container .content').animate({
        marginRight: "0px",
        opacity: 1		
      }, 700);
	
	//$('.background').css("opacity", "0.7");
}

function animate_close_content(callback)
{
	$('.content_container .content').animate({
        marginRight: "70px",
        opacity: 0
      }, 700,
	  callback);
}

function make_awards_carousel()
{
	if( !$('#awards_list').hasClass("jcarousel-list") )
	{
		$('#awards_list').css({
			overflow: "hidden"
		});
		$('#awards_list').jcarousel({
			vertical: true,
			scroll: 2,
			animation: 'slow'
		});
	}
}

var office = null;

function load_map()
{
	office = new GLatLng(-31.949637, 115.845197);

	if( $('#mu_location').children().length == 0 )
	{
		switch_street()
	}
}

function switch_street()
{
	var panoramaOptions = { latlng:office };
	var myPano = new GStreetviewPanorama(document.getElementById("mu_location"), panoramaOptions);
	GEvent.addListener(myPano, "error", switch_map);

	if (GBrowserIsCompatible() )
	{
		$('#map_container a').unbind();
		$('#map_container a').click( function()
		{
			switch_map();
			return false;
		});
	}
}

function switch_map()
{
	var map = new GMap2(document.getElementById("mu_location"));
	map.addControl(new GSmallMapControl());
	map.addOverlay(new GMarker(office));
	map.setCenter(office, 15);

	$('#map_container a').unbind();
	$('#map_container a').click( function()
	{
		$('#map_container a')
		switch_street();
		return false;
	});
}

