//window.addEvent('domready', function () {

//    $('one').addEvent('click', function () {
//        slideshow.options.auto = this.checked;
//    });

//    $('two').addEvent('click', function () {
//        slideshow.options.auto = this.checked;
//    });

//    $('three').addEvent('click', function () {
//        slideshow.options.auto = this.checked;
//    });

//    var slideshow = new BarackSlideshow('slideMenu', 'pictures', 'loading', { transition: 'fade', autostart: true, auto: true, autointerval: 5000 });
//});

$(function () {
    $("#pictures li").not(":first-child").hide();
    $("#slideMenu li:first-child").addClass("current");

    $("ul#slideMenu li").click(function () {
        //Change the "current" tab
        var idx = $("#slideMenu li.current").index();
        $("#slideMenu li").removeClass("current");
        $(this).addClass("current");

        //Update the tab image
        var newIdx = $("#slideMenu li.current").index();
        $("#pictures li:nth-child(" + (idx + 1) + ")").hide();
        $("#pictures li:nth-child(" + (newIdx + 1) + ")").show();
    });
});
