hs.graphicsDir = 'sider/script/highslide/graphics/';
hs.dimmingOpacity = 0.75;
hs.captionEval = 'this.thumb.alt';
hs.allowMultipleInstances = false;
hs.transitions = ['expand', 'crossfade'];
hs.outlineType = 'rounded-white';
hs.fadeInOut = true; 
hs.align="center";
hs.registerOverlay({
    html: '<div class="closebutton" onclick="return hs.close(this)" title="Lukk"></div>',
    position: 'top right',
    useOnHtml: true,
    fade: 2 // fading the semi-transparent overlay looks bad in IE
});

hs.Expander.prototype.onAfterExpand = function (sender) {
    try{
        var width1=bodyWidth();
        document.body.scroll="no";
        document.body.style.overflow="hidden";
        var width2=bodyWidth();
        document.body.style.marginRight=(width2-width1)+"px";
    }catch(e){
    }
}

hs.Expander.prototype.onAfterClose = function (sender) {
    try{
        document.body.scroll="yes";
        document.body.style.overflow="auto";
        document.body.style.marginRight="";
    }catch(e){
    }
}

// Norwegian (nynorsk) language strings
hs.lang = {
    cssDirection: 'ltr',
    loadingText: 'Lastar...',
    loadingTitle: 'Klikk for å avbryte',
    focusTitle: 'Klikk for å flytte fram',
    fullExpandTitle: 'Utvid til full storleik',
    creditsText: 'Drive av <i>Highslide JS</i>',
    creditsTitle: 'Gå til Highslide JS si heimeside',
    previousText: 'Forrige',
    nextText: 'Neste',
    moveText: 'Flytt',
    closeText: 'Lukk',
    closeTitle: 'Lukk (esc)',
    resizeTitle: 'Endre storleik',
    playText: 'Spel av',
    playTitle: 'Vis biletserie (mellomrom)',
    pauseText: 'Pause',
    pauseTitle: 'Pause (mellomrom)',
    previousTitle: 'Forrige (pil venstre)',
    nextTitle: 'Neste (pil høgre)',
    moveTitle: 'Flytt',
    fullExpandText: 'Full storleik',
    number: 'Bilete %1 av %2',
    restoreTitle: 'Klikk for å lukke biletet, klikk og dra for å flytte. Bruk piltastane for forrige og neste.'
};

function bodyWidth(){
    return document.body.offsetWidth;
}
