// initialize slideshow (Cycle)
jQuery(document).ready(function() {
	if ($j('#Slides').length > 0) {
		$j('#Slides').cycle({ 
			fx: 'fade,fade,fade,fade,fade,fade,fade',						
			speed: 750,
			timeout:  5000, 
			randomizeEffects: false, 
			easing: 'easeOutCubic',
			next:   '.slideNext', 
			prev:   '.slidePrev',
			pager:  '#slidePager',
			cleartypeNoBg: true,
			before: function() {
				// reset the overlay for the next slide
				$j('#SlideRepeat').css('cursor','default').unbind('click'); },
			after: function() {
				// get the link and apply it to the overlay
				var theLink = $j(this).children('a');
				var linkURL = (theLink) ? theLink.attr('href') : false;
				if (linkURL) {
					$j('#SlideRepeat').css('cursor','pointer').click( function() {
						document.location.href = linkURL;
					});
				}
			}
		});
	}
});
