function mycarousel_initCallback(carousel)
{
    // Disable autoscrolling if the user clicks the prev or next button.
    carousel.buttonNext.bind('click', function() {
        carousel.startAuto(0);
    });

    carousel.buttonPrev.bind('click', function() {
        carousel.startAuto(0);
    });

    // Pause autoscrolling if the user moves with the cursor over the clip.
    carousel.clip.hover(function() {
        carousel.stopAuto();
    }, function() {
        carousel.startAuto();
    });

    $('marquee').marquee();
};

$(function() {
 $("a[rel='Gallery']").colorbox();
 resize();


 $('#cycleleft1').cycle({
    fx: 'scrollLeft',
    timeout: 3000,
    cleartype: false
 });

 $('#cycleleft2').cycle({
    fx: 'fade',
    timeout: 2000,
    speed: 1000,
    cleartype: false
 });

 $('#carousel1').jcarousel({
    	wrap: 'circular',
        vertical: true,
        buttonNextHTML: null,
        buttonPrevHTML: null,
        auto: 1,
        scroll: 1,
        initCallback: mycarousel_initCallback,
        animation: 3000
    });
});

function resize()
{
    var pageWidth = $(window).width();
    $("#Main_ContentCenter").width(pageWidth-230-218-36-100);
}
