function slideSwitch() {
    var $active = $('#slideshow div.active');

	$active.addClass('last-active');

    var $next =  $active.next().length ? $active.next() : $('#slideshow div:first');

    $next.css({opacity: 0.0,'height': '218px'})
        .addClass('active')
        .animate({opacity: 1.0}, 1000, function() {
            $active.removeClass('active last-active');
        });
}
function slideSwitchDois() {
    var $active = $('#slideshow_footer img.active');

	$active.addClass('last-active');

    var $next =  $active.next().length ? $active.next() : $('#slideshow_footer img:first');

    $next.css({opacity: 0.0})
        .addClass('active')
        .animate({opacity: 1.0}, 1000, function() {
            $active.removeClass('active last-active');
        });
}
function slideSwitchQuatro() {
    var $active = $('#slideshow_footer_dois img.active');

	$active.addClass('last-active');

   var $next =  $active.next().length ? $active.next() : $('#slideshow_footer_dois img:first');

    $next.css({opacity: 0.0})
        .addClass('active')
        .animate({opacity: 1.0}, 1000, function() {
            $active.removeClass('active last-active');
        });
}

$(document).ready(function() {
	//setInterval("slideSwitch()", 6000);
		$(document).ready(function() {
	    $('#slideshow_centro').cycle({
			fx: 'fade',
			timeout: 6000
		});
	    $('#slideshow_pagina').cycle({
			fx: 'fade',
			timeout: 6000
		});
	    $('#slideshow_footer_dois').cycle({
			fx: 'fade',
			timeout: 3000
		});
	    $('#slideshow_footer').cycle({
			fx: 'fade',
			timeout: 7000
		});
	    $('#slideshow').cycle({
			fx: 'fade',
			timeout: 5000, 
			cleartypeNoBg: true,
			cleartype: true
		});
	});	
});
