$(document).ready(
	function(){
		// start the cycling of the header images
		$('ul.headercycle').cycle({
			speed: 2000,   // fade time
			timeout: 5000, // time to next slide
			fx: 'fade'
		});
		
		$('#resumeButton').click(function() { 
		    $('ul.innerfade').cycle('resume'); 
		});
	}
);


// this appears to work properly to stop the cycle when the colorbox loads
$(document).bind('cbox_load', function(){
	$('ul.innerfade').cycle('pause'); 
});

/*
 * One of the two below should be able to resume cycle, but they either don't work, or stop the colorbox closing...
 * 
 * 
$(document).bind('cbox_cleanup', function(){
	$('ul.innerfade').cycle('resume'); 
//	return true;  // don't know if this might help?  Doesn't seem to...
});

*/
$(document).bind('cbox_closed', function(){
	$('ul.innerfade').cycle('resume');
	//alert("yo");
});
/**/

