jQuery.noConflict();

var theInterval = null;

doInterval = function(){
	clearInterval(theInterval);
	theInterval = setInterval(function(){
		//$stripNavlink.trigger('click');
		$stripNavlink.triggerHandler('click');
	}, 5000);
};

stopInterval = function(){
	clearInterval(theInterval);
};

jQuery(document).ready(function($) {
	$("div#slider1").codaSlider()
	$("div#slider-wrap").mouseover(function() {
		stopInterval();
		return false;
	});
	$("div#slider-wrap").mouseout(function() {
		doInterval();
		return false;
	});
	
	$stripNavlink = $("#stripNavR0 a");
	/*$("#stripNavR0 a").click(function() {
		doInterval();
		return false;
	});*/
	
	doInterval();
});

jQuery(function($){
	$('#nav a')
		.css( {backgroundPosition: "0 0"} )
		.mouseover(function(){
			$(this).stop().animate({backgroundPosition:"(0 -42px)"}, {duration:500})
		})
		.mouseout(function(){
			$(this).stop().animate({backgroundPosition:"(0 0)"}, {duration:500, complete:function(){
				$(this).css({backgroundPosition: "0 0"})
			}})
		})
		$('#nav .selected')
		.css( {backgroundPosition: "0 -42px"} )
		.mouseout(function(){
			$(this).stop().animate({backgroundPosition:"(0 -42px)"}, {duration:500, complete:function(){
				$(this).css({backgroundPosition: "0 -42px"})
			}})
		})
});