// JavaScript Document

function startSliceShows(){
	var nrOfSlidesShow1=8;
	var nrOfSlidesShow2=9;
	var nrOfSlidesShow3=5;
	
	var firstFrameIndex=1;
	var startSlideShow1=Math.floor(Math.random( ) * nrOfSlidesShow1 - firstFrameIndex + 1) + firstFrameIndex;
	var startSlideShow2=Math.floor(Math.random( ) * nrOfSlidesShow2 - firstFrameIndex + 1) + firstFrameIndex;
	var startSlideShow3=Math.floor(Math.random( ) * nrOfSlidesShow3 - firstFrameIndex + 1) + firstFrameIndex;
	
	$('slideshow1_'+startSlideShow1 ).show();	
	$('slideshow2_'+startSlideShow2 ).show();
	$('slideshow3_'+startSlideShow3 ).show();
	
	setTimeout(switch_slides('slideshow1_',startSlideShow1,firstFrameIndex, nrOfSlidesShow1, 24000), 16000);
	setTimeout(switch_slides('slideshow2_',startSlideShow2,firstFrameIndex, nrOfSlidesShow2, 24000), 8000);
	setTimeout(switch_slides('slideshow3_',startSlideShow3,firstFrameIndex, nrOfSlidesShow3, 24000), 24000);
}
function beforeBodyLoad(){
	displayNoneByJS();//Apply class="displayNoneByJS"
	//adaptContentToBrowserHeight();
}
function onBodyLoad(){
	/*
	var vertMenuFromUL_activePath=[];
	var vertMenuFromULBlue_activePath=[0];
	var vertMenuFromULRed_activePath=[0];
	var vertMenuFromULGreen_activePath=[0];
	var vertMenuFromULTail_activePath=[];
	*/
	
	if( $('vertMenuFromUL') != null ){
		if( typeof(vertMenuFromUL_activePath) != 'undefined' ){
			listHighlightAndCollapse($('vertMenuFromUL'),vertMenuFromUL_activePath);
		}//else{//Depth of the list will not be changed }	
		$('vertMenuFromUL').className = "";			//undo displayNoneByJS
	}
	if( $('vertMenuFromULBlue') != null ){	
		if(typeof(vertMenuFromULBlue_activePath) != 'undefined' ){
			listHighlightAndCollapse($('vertMenuFromULBlue'),vertMenuFromULBlue_activePath);
		}//else{//Depth of the list will not be changed }	
		$('vertMenuFromULBlue').className = "";		//undo displayNoneByJS
	}
	if( $('vertMenuFromULRed') != null ){	
		if(typeof(vertMenuFromULRed_activePath) != 'undefined' ){
			listHighlightAndCollapse($('vertMenuFromULRed'),vertMenuFromULRed_activePath);
		}//else{//Depth of the list will not be changed }	
		$('vertMenuFromULRed').className = "";		//undo displayNoneByJS
	}
	if( $("vertMenuFromULGreen") != null ){	
		if(typeof(vertMenuFromULGreen_activePath) != 'undefined' ){
			listHighlightAndCollapse($("vertMenuFromULGreen"),vertMenuFromULGreen_activePath);
		}//else{//Depth of the list will not be changed }	
		$("vertMenuFromULGreen").className = "";	//undo displayNoneByJS
	}
	if( $("vertMenuFromULTail") != null ){	
		if(typeof(vertMenuFromULTail_activePath) != 'undefined' ){
			listHighlightAndCollapse($("vertMenuFromULTail"),vertMenuFromULTail_activePath);
		}//else{//Depth of the list will not be changed }	
		$("vertMenuFromULTail").className = "";		//undo displayNoneByJS
	}
	adaptContentToBrowserHeight();	

	startSliceShows();
}
function adaptContentToBrowserHeight(){
	$('minHeight').style.height = document.body.parentNode.clientHeight-285-75 + 'px';
	rule = getCSSRule(".hightByJS");
	if(rule){
		rule.style.height = document.body.parentNode.clientHeight-285-75 + 'px';	
	}
}

beforeBodyLoad();//Execute the beforeBodyLoad function
