var mySlideShow;
	var mySlideShowOptions;

	$(document).ready(function() {
	mySlideShow=$('#slideshow').cycle({
	fx: 'fade',
	timeout: 5000,
	next:'#slideshow-next',
	prev:'#slideshow-previous',
	before:slideShowInit
	}); 
	
    $('#slideshow a').lightBox()
});
	function beforeLightBoxInitialize(){
		$('#slideshow').cycle('pause');
	}
	function afterLightBox(){
		$('#slideshow').cycle('resume');
	}
	function slideShowInit(curr, next, opts, fwd){
		mySlideShowOptions=opts;
	}
						   
		
		function showNext(){
			
			mySlideShowOptions.fx="scrollLeft";
			$('#slideshow').cycle.next(mySlideShowOptions);
		}
		
		function showPrevious(){
			
			mySlideShowOptions.fx="scrollRight";
			$('#slideshow').cycle.prev(mySlideShowOptions);
			window.setTimeout('resetScrollDirection()',1000)
		}
	function resetScrollDirection(){
		mySlideShowOptions.fx="scrollLeft";
		}
