
	var Move = function(target, current){
		move = -(current*455);
		$(target+' > div').stop(true, true).animate({'marginLeft':move+'px'});
		$(target+' ul li a').removeClass('select');
		$(target+' ul li a[num='+current+']').addClass('select');
	}
	
	var Player = function(current){
		move = -(current*711);
		$('div#player div ul').stop(true, true).animate({'marginLeft':move+'px'});
		$('div#player ul li a').removeClass('select');
		$('div#player ul li a[num='+current+']').addClass('select');
	}
	
	var current = 0;

	$(document).ready(function(){
		$('div.mini-actu ul li a').click(function(e){
			e.preventDefault();
			Move('.mini-actu', $(this).attr('num'))
		});
		$('div.mini-blog ul li a').click(function(e){
			e.preventDefault();
			Move('.mini-blog', $(this).attr('num'))
		});
		$('ul.link li a').click(function(e){
			e.preventDefault();
			$(document).stopTime("switch");
			Player($(this).attr('num'));
		});
		
		$('div.box').hover(
			function(){
				$(this).children('div.hover').stop(true, true).animate({'marginTop':'-174px'});
			},function(){
				$(this).children('div.hover').stop(true, true).animate({'marginTop':'0px'});
		});
	});
		
	$(document).everyTime(5000, "switch", function() {
		current++;
		if(current==5) current = 0;
		Player(current);
	});
