$(document).ready(function(){

	Shadowbox.init();
			
	$('#slides').cycle({
		speed: 3000,
		timeout:  8000, 
		randomizeEffects: false, 
		easing: 'easeOutCubic',
		pager:  '#slidePager',
		cleartypeNoBg: true
	});

	$('#laflotte-slides').cycle({
		speed: 1200,
		timeout:  8000, 
		randomizeEffects: false, 
		easing: 'easeOutCubic',
		pager:  '#laflotte-photoSlider',
		cleartypeNoBg: true
	});

	$('#laflotte-cycle').cycle({
		speed: 1200,
		timeout:  4000, 
		randomizeEffects: false, 
		easing: 'easeOutCubic',
		cleartypeNoBg: true,
		after: function(a, b){
		
		},
		before: function(a, b){
			$('#laflotte-helicopter').fadeOut(400, function(){
				$(this).text( $(b).attr('alt') );
				$(this).fadeIn(500);
			});
			
		}
	});
	
	// Google Maps in Contact page
	if ($('#map_canvas').length){
		var latlng = new google.maps.LatLng(46.794988,-71.375);
		var settings = {
			zoom: 15,
			center: latlng,
			mapTypeControl: true,
			mapTypeControlOptions: {style: google.maps.MapTypeControlStyle.DROPDOWN_MENU},
			navigationControl: true,
			navigationControlOptions: {style: google.maps.NavigationControlStyle.SMALL},
			mapTypeId: google.maps.MapTypeId.ROADMAP};
		var map = new google.maps.Map(document.getElementById("map_canvas"), settings);
		var companyImage = new google.maps.MarkerImage('/wp-content/themes/ch2/images/chgoogle.png',
			new google.maps.Size(1230,79),
			new google.maps.Point(0,0),
			new google.maps.Point(28,79)
		);
		var companyPos = new google.maps.LatLng(46.7952,-71.3810);
		var companyMarker = new google.maps.Marker({
			position: companyPos,
			map: map,
			icon: companyImage,
			title:"Capitale Helicoptere",
			zIndex: 3});
	}

});



