$(document).ready(function() {

    /* Blog menu start */
    $(".year").click(function() {
        var ul = $(this).parent().find(".months");
        if (ul.css('display') == 'none')
            ul.show('fast');
        else
            ul.hide('fast');
    })
    $(".month").click(function() {
        var list = $(this).parent().find(".articles");
        if (list.css('display') == 'none')
            list.show('fast');
        else
            list.hide('fast');
    })
    $(".Current").parent().show();
    /* Blog menu end */

    $('img').bind("contextmenu", function(e) {
        //$("#ShowRightClick").trigger('click');
        return false;
    });


    $(".scroll").scrollable({
        circular: false,
        easing: "swing",
        mousewheel: true,
        speed: '200'
    });


});

$(window).bind('load', function() {
    var preload = new Array();
    $(".fancybox").each(function() {
        s = $(this).attr("href");
        preload.push(s)
    });
    var img = document.createElement('img');
    $(img).bind('load', function() {
        if (preload[0]) {
            this.src = preload.shift();
        }
    }).trigger('load');
});
