function init(tabNum) {
	initHeight(tabNum, 'auto');
}

function initHeight(tabNum, height) {
    if(tabNum == null)
        tabNum = 0
    var roundCorners = Rico.Corner.round.bind(Rico.Corner);
    roundCorners('centerContent');
    roundCorners('leftContent');

    var accordionOptions = {
        panelHeight:height,
        expandedBgImg: 'url(images/leftHeaderSelected.jpg)',
        expandedBg: null,
        hoverBg: null,
        collapsedBgImg: 'url(images/leftHeaderUnselected.jpg)',
        collapsedBg: null,
        borderColor: '#d5dcd9',
        onLoadShowTab: tabNum
    };
    new Rico.Accordion( 'accordion', accordionOptions );
}

function leftContentScroll(parentDiv,element) {
    var a = element.offsetTop;
    var b = 0;
    if(parentDiv.firstChild.firstChild != null)
        b = parentDiv.firstChild.firstChild.offsetTop;
    else
        b = parentDiv.firstChild.nextSibling.firstChild.nextSibling.offsetTop;
    var h = element.offsetHeight / 2;
    var ch = parentDiv.clientHeight / 2;
    parentDiv.scrollTop = a - b + h - ch;
}

function showDisclaimer() {
    $('oanv').style.visibility = "hidden";
    $('oanvd').style.visibility = "visible";
    $('oanv').style.display = "none";
    $('oanvd').style.display = "inline";

/*
    clientWidth = window.innerWidth != null? window.innerWidth: document.body.clientWidth != null? document.body.clientWidth:null;
    dwidth = $('centerContentDisclaimer').offsetWidth;
    clientHeight = window.innerHeight != null? window.innerHeight: document.body.clientHeight != null? document.body.clientHeight:null;
    dheight = $('centerContentDisclaimer').offsetHeight;
    y = (clientHeight / 2 ) - (dheight / 2);
    x = (clientWidth / 2) - (dwidth / 2);
    $('centerContentDisclaimer').style.left = x + 'px';
    $('centerContentDisclaimer').style.top = y + 'px';
    $('centerContentDisclaimer').style.visibility = "visible";
*/
}

function hideDisclaimer() {
/*
    $('centerContentDisclaimer').style.visibility = "hidden";
*/
    $('oanv').style.visibility = "visible";
    if (BrowserDetect.browser == "Explorer" && BrowserDetect.version < 7)
        $('oanv').style.display = "inline";
    else
        $('oanv').style.display = "";
    $('oanvd').style.display = "none"; 
    $('oanvd').style.visibility = "hidden";

}

