/*************  chargé au lancement : **********/

if (window.attachEvent) window.attachEvent("onload", sfHover);

function sfHover() {
    
    var sfEls = $("menu").children("li");
    for (var i=0; i<sfEls.length; i++) {
        sfEls[i].onmouseover=function() {
            this.className+=" sfhover";
        }
        sfEls[i].onmouseout=function() {
            this.className=this.className.replace(new RegExp(" sfhover\\b"), "");
        }
    }
}
/*************************************************/

/********* Fonction hover pour le menu ***********/
function PinkHover (id) {
    
    $(id).css({background: "url(images/menu_bg_hover.png) repeat-x"});
}

function invisible (id) {

    $(id).css({background: "url(images/menu_bg.png) repeat-x"});
}

var Page = 1;
var PageActuelle = 0;

function isset () {
    
    var a=arguments, l=a.length, i=0;
    
    if (l===0) {
        throw new Error('Empty isset'); 
    }
    
    while (i!==l) {
        if (typeof(a[i])=='undefined' || a[i]===null) { 
            return false; 
        } else { 
            i++; 
        }
    }
    return true;
}

jQuery(document).ready(
    function(){
        $(function() {
            var icons = {
                header: "ui-icon-circle-arrow-e",
                headerSelected: "ui-icon-circle-arrow-s"
            };  
            $("#accordion").accordion({
                icons: icons
            });
            $("#toggle").button().toggle(function() {
                $("#accordion").accordion("option", "icons", false);
            }, function() {
                $("#accordion").accordion("option", "icons", icons);
            });
            $("a[rel='galerie']").colorbox(); 
        });
    }
);

jQuery(document).ready(function(){
    jQuery('#slide1dv').slideshow(
        {
            width:680,
            height:300,
            playframe:false,
            title:false,
            panel:false,
            effect:'random'
        }
        ).playSlide();
});

jQuery(document).ready(function(){
    jQuery('#slide2dv').slideshow(
        {
            width:700,
            height:300,
            playframe:false,
            title:false,
            panel:false,
            effect:'random'
        }
        ).playSlide();
});

jQuery(document).ready(function(){
    jQuery('#slide3dv').slideshow(
        {
            width:375,
            height:300,
            playframe:false,
            title:false,
            panel:false,
            effect:'random'
        }
        ).playSlide();
});

jQuery(document).ready(function(){
    jQuery('#slide4dv').slideshow(
        {
            width:300,
            height:300,
            playframe:false,
            title:false,
            panel:false,
            effect:'random'
        }
        ).playSlide();
});

jQuery(document).ready(function(){
    jQuery('#slide5dv').slideshow(
        {
            width:348,
            height:300,
            playframe:false,
            title:false,
            panel:false,
            effect:'random'
        }
        ).playSlide();
});
DD_roundies.addRule('.rounded8px', '8px');

iBox.padding = 50;
iBox.inherit_frames = false;
iBox.default_width = 480;