﻿jQuery(document).ready(function()
{
	jQuery('#LibraryServices dl').css({ display: '' });
	jQuery('#LibraryServices').tabs('.services dd', { tabs: 'dt', effect: 'fade' });
});


/**
* We use the initCallback callback
* to assign functionality to the controls
*/
function mycarousel_initCallback(carousel)
{
	// Pause autoscrolling if the user moves with the cursor over the clip.
	carousel.clip.hover(function()
	{
		carousel.stopAuto();
	}, function()
	{
		carousel.startAuto();
	});

	jQuery('#mycarousel-next').bind('click', function()
	{
		carousel.next();
		return false;
	});

	jQuery('#mycarousel-prev').bind('click', function()
	{
		carousel.prev();
		return false;
	});
};

// Ride the carousel...
jQuery(document).ready(function()
{
	jQuery("#mycarousel ul li").css({ display: "" });
	jQuery("#mycarousel").jcarousel({
		auto: 5,
		wrap: 'last',
		scroll: 1,
		initCallback: mycarousel_initCallback,
		// This tells jCarousel NOT to autobuild prev/next buttons
		buttonNextHTML: null,
		buttonPrevHTML: null
	});

});
