$(function() {
   /*  //Set the default item to display on load.  
    //Correct indexing  

    function setDefault($n) {
        defaultItem = $n - 1;
    }
    var html = $('div.wrapper').html();
    var imageCaption = $('#imageCaption');
    $('div.wrapper').parent().append(html).end().remove();
    $sliderCtrl = $('#slider');
    $coverflowCtrl = $('#coverflow');
    $coverflowImages = $coverflowCtrl.find('img');
    $sliderVertical = $("#slider-vertical");
    //app defaults  
    var defaultItem = 0;
    var listContent = "";
    //Set the default image index.  
    setDefault(2);

  
   

   //Initialize CoverFlow  
    $coverflowCtrl.coverflow({
        item: defaultItem,
        duration: 1200,
        select: function(event, sky) {
            skipTo(sky.value);
        }
    });
    //Initialize Horizontal Slider  
    $sliderCtrl.slider({
        min: 0,
        max: $('#coverflow > *').length - 1,
        value: defaultItem,

        slide: function(event, ui) {
            $coverflowCtrl.coverflow('select', ui.value, true);
            $('.coverflowItem').removeClass('ui-selected');
            $('.coverflowItem:eq(' + (ui.value) + ')').addClass('ui-selected');
           
        }
    });
    //Skip to an item in the CoverFlow  

    function skipTo($itemNumber) {
        $sliderCtrl.slider("option", "value", $itemNumber);
        $coverflowCtrl.coverflow('select', $itemNumber, true);
        $('.coverflowItem').removeClass('ui-selected');
        $('.coverflowItem:eq(' + ($itemNumber) + ')').addClass('ui-selected');

    }
    //Skip all controls to the current default item  
    $('#sortable').html(listContent);
    skipTo(defaultItem);
    //Assign click event for coverflow images  
    $('body').delegate('.coverflowItem', 'click', function() {
        skipTo($(this).data('itemlink'));
    }); */
	
	$('#background-slideshow').jCarouselLite({
    btnNext: "#prev",
    btnPrev: "#next",
	circular: true
});
$('#main-slideshow').cycle({
	prev: $('#prev'),
	next: $('#next'),
	timeout: 0
});	

}); 
