$(document).ready(function() {

    $('#menu a.dropdown').css('background-image', 'none');
    $('#menu a.dropdown').hover(function() {
            $(this).css({'text-decoration':'none', 'cursor':'default'});
    });

    // $('#menu a.dropdown').css('pointer-events', 'none');
    $('#menu a.dropdown').click(function(e) {
            e.preventDefault();
    });
    $('#menu a.dropdown').before('<span class="dropdownarrow"></span>')
    $('.dropdownarrow').css({"pointer-events":"none", "content":"''", "z-index":"100", "width":"0", "height":"0", "position":"absolute", "left":"17px", "border-width":"6px", "margin-left":"-6px", "margin-top":"-3px", "top":"50%", "border-style":"solid", "border-color": "#ffffff transparent transparent transparent"});

    $('a').focus(function() {
            $('.sfhover').removeClass('sfhover');
            $('.dropdown').parent().has($(this)).addClass('sfhover');
            $('*:hover').mouseout();
    });
    $('a').blur(function() {
            $('.dropdown').parent().has($(this)).removeClass('sfhover');
    });
    $('a').hover(function() {
            $('*:focus').blur(); 
    });
    // $('.dropdown').parent().hover(function() {
    //         $(this).children('.dropdownarrow').stop(true, true).fadeOut();
    //     }, function() {
    //         $(this).children('.dropdownarrow').stop(true, true).fadeIn();
    // });
    jQuery('#slideshow').stop(true,true).fadeSlideShow({            
            width: 980, // default width of the slideshow
            height: 300, // default height of the slideshow
            speed: 'slow', // default animation transition speed
            interval: 10000, // default interval between image change
            PlayPauseElement: 'fssPlayPause', // default css id for the play / pause element
            PlayText: 'Play', // default play text
            PauseText: 'Pause', // default pause text
            NextElement: 'fssNext', // default id for next button
            NextElementText: 'Next >', // default text for next button
            PrevElement: 'fssPrev', // default id for prev button
            PrevElementText: '< Prev', // default text for prev button
            ListElement: 'fssList', // default id for image / content controll list
            ListLi: 'fssLi', // default class for li's in the image / content controll 
            ListLiActive: 'fssActive', // default class for active state in the controll list
            addListToId: false, // add the controll list to special id in your code - default false
            allowKeyboardCtrl: false, // allow keyboard controlls left / right / space
            autoplay: true // autoplay the slideshow
            
        });
});
