


$(function() {
    // add a 'js' class to the body
    $('body').addClass('js');
    
    // initialise the slideshow when the DOM is ready
/*    $slideshow.init();*/
var slideshow = function(){
	var target = $('#slideshow .slides ul');
	var nav = $('#slideshow .slides-nav li');
	var aaa = function(){
		console.log(target.cycle.timeout);
	}

	target.cycle({
		fx: 'scrollLeft',
		//timeout: 6000,
		speed: 1000,
		before: function(){
			nav.removeClass('on');
			nav.eq($(this).index()).addClass('on');
		}
	});

	nav.mouseenter(function(){
		nav.not($(this)).removeClass('on');
		$(this).addClass('on');
		target.cycle($(this).index()).cycle('pause');
	}).mouseleave(function(){
		target.cycle('resume');
	});
}
if($('#slideshow').size()) slideshow();

});


