function slideSwitch() {
	var $active = $('.newslideshow div.active');
	
    if ( $active.length == 0 ) $active = $('.newslideshow div:last');
    var $next =  $active.next().length ? $active.next()
        : $('.newslideshow div:first');
	
    $active.addClass('last-active');
	$('div.cluetip').animate({height: '0'},450, function() {
		$('div:first div.cluetip').animate({height: '20'},450);
	});
	$next.css({opacity: 0.0})
		.addClass('active')
		.animate({opacity: 1.0}, 1500, function() {
			/*switch ($next.css('opacity'))
				{
				case "1":
					$('.cluetip').animate({height: '20px'},500);
					break;
				}*/
			//$('div.cluetip').animate({height: '20px'},500);
            $active.removeClass('active last-active');
        });

	var $active2 = $('.newslideshow2 div.active');
	
    if ( $active2.length == 0 ) $active2 = $('.newslideshow2 div:last');
    var $next2 =  $active2.next().length ? $active2.next()
        : $('.newslideshow2 div:first');
	
    $active2.addClass('last-active');
	$('div.cluetip').animate({height: '0'},450, function() {
		$('div:first div.cluetip').animate({height: '20'},450);
	});
	$next2.css({opacity: 0.0})
		.addClass('active')
		.animate({opacity: 1.0}, 1500, function() {
			/*switch ($next.css('opacity'))
				{
				case "1":
					$('.cluetip').animate({height: '20px'},500);
					break;
				}*/
			//$('div.cluetip').animate({height: '20px'},500);
            $active2.removeClass('active last-active');
        });

}

$(function() {
	setInterval( "slideSwitch()", 5000 );
	
});


 
 
 $(document).ready(function(){					
	slideSwitch();
});

