if(window.scrollbars)
window.scrollbars.visible=false;
var DOM=(document.getElementById?true:false);
var IE4=((document.all&&!DOM)?true:false);
var NS4=(document.layers?true:false);
var Dyn=(DOM||IE4||NS4);
function getRef(id){if(DOM)return document.getElementById(id);if(IE4)return document.all[id];if(NS4)return document.layers[id];}
function getSty(id){return (NS4?getRef(id):getRef(id).style);}
function scrFileLoaded(){with(this){activeScr=null;scrollBy(-100000);for(count=0;count<divs.length;count++)getSty(divs[count][0]).visibility='visible';}}
function scrScrollBy(amount){with(this){if(!Dyn||!loaded)return;amount=parseInt(amount);divHeight=document.all?divRef.clientHeight:(DOM?divRef.offsetHeight:divRef.document.height);if(divHeight==0)divHeight=1;if((cBot+amount)>=divHeight)amount=divHeight-cBot;if((cTop+amount)<0)amount=0-cTop;cTop+=amount;cBot+=amount;if(DOM||IE4)divSty.clip='rect('+cTop+'px '+cWidth+'px '+cBot +'px 0px)';else if(NS4){if(isNaN(cTop)||isNaN(cBot)||isNaN(amount))layout();if(cBot<divSty.clip.top)divSty.clip.top=cTop;divSty.clip.bottom=cBot;divSty.clip.top=cTop;}divSty.top=eval(divs[0][2])-cTop;thmHeight=10;if(thmHeight<minThmHeight)thmHeight=minThmHeight;if(thmHeight>barHeight)thmHeight=barHeight;if(DOM||IE4)thmSty.height=thmHeight;else if(NS4)thmSty.clip.height=thmHeight;if(activeScr)return;fracDivDown=(cTop/(divHeight-(cBot-cTop)));fracDivDown=(isNaN(fracDivDown))?0:fracDivDown;thmSty.top=parseInt(barSty.top)+fracDivDown*(barHeight-thmHeight);if(loop)setTimeout(myName+'.scrollBy('+amount+')',loop);}}
function scrThumbDown(evt){activeScr=this;if(document.all)scrOffset=event.offsetY;else scrOffset=evt.layerY;return false;}
function scrThumbMove(evt){if(NS4)document.routeEvent(evt);if(!activeScr)return true;else {with(activeScr){if((cBot>divHeight)||(thmHeight==barHeight))return;if (document.all)newTop=document.body.scrollTop+event.clientY-scrOffset;else newTop=evt.pageY-scrOffset;var barTop=parseInt(barSty.top);if(newTop<barTop)newTop=barTop;if(newTop+thmHeight>(barTop+barHeight))newTop=(barTop+barHeight)-thmHeight;thmSty.top=newTop;fracDivDown=cTop/(divHeight-(cBot-cTop));fracBarDown=(newTop-barTop)/(barHeight-thmHeight);if(isNaN(fracDivDown))return;scrollBy((fracBarDown-fracDivDown)*(divHeight-(cBot-cTop)));return false;}}}
function scrThumbUp(evt){if(NS4)document.routeEvent(evt);activeScr=null;}
function scrBarClick(evt){with(this){if(NS4)document.routeEvent(evt);if(document.all)clickPos=document.body.scrollTop+event.clientY;else clickPos=evt.pageY;if(clickPos<parseInt(thmSty.top))scrollBy(cTop-cBot);if(clickPos>(parseInt(thmSty.top)+thmHeight))scrollBy(cBot-cTop);}}
function scrLayout(){with(this){if(!Dyn)return;winWidth=getWidth();winHeight=getHeight();if(NS4&&(scrFirstWidth!=winWidth)){fileName=location.href;if(fileName.indexOf('?')!=-1)fileName=fileName.substring(0,fileName.indexOf('?'));location.href=fileName+'?loadFile='+divRef.src;}if(!loaded)return;if(winWidth<minWinWidth)winWidth=minWinWidth;if(winHeight<minWinHeight)winHeight=minWinHeight;for(count=0;count<divs.length;count++){var tmpObj=getSty(divs[count][0]);if(divs[count][1])tmpObj.left=eval(divs[count][1]);if(divs[count][2])tmpObj.top=eval(divs[count][2]);if(divs[count][3]){var tmpW=eval(divs[count][3]);NS4?tmpObj.clip.width=tmpW:tmpObj.width=tmpW;}if(divs[count][4]&&count!=0){var tmpH=eval(divs[count][4]);NS4?tmpObj.clip.height=tmpH:tmpObj.height=tmpH;}}if((DOM||IE4)&&!cTop)cTop=0;if(NS4)cTop=divSty.clip.top;barHeight=eval(divs[1][4]);cBot=cTop+eval(divs[0][4]);cWidth=eval(divs[0][3]);if(DOM||IE4)divSty.width=cWidth;scrollBy(0);}}
function scrSetup(){with(this){if(!Dyn)return;divRef=getRef(divs[0][0]);divSty=getSty(divs[0][0]);barSty=getSty(divs[1][0]);thmSty=getSty(divs[2][0]);barRef=getRef(divs[1][0]);thmRef=getRef(divs[2][0]);if(NS4){barRef.captureEvents(event.CLICK);thmRef.captureEvents(event.MOUSEDOWN);document.captureEvents(event.MOUSEMOVE|event.MOUSEUP);}thmRef.onmousedown=new Function('evt','return '+myName+'.thumbDown(evt)');document.onmousemove=scrThumbMove;document.onmouseup=scrThumbUp;if(document.all)document.onselectstart=new Function('if(activeScr) return false');else if(DOM)document.onselect=new Function('if(activeScr) return false');loaded=true;layout();fileLoaded();}}
function DHTMLScroller(myName){this.divRef=null;this.divSty=null;this.barSty=null;this.thmSty=null;this.divs=new Array();this.bufRef=null;this.myName=myName;this.loaded=false;this.loop=0;this.minThmHeight=20;this.divHeight=0;this.barHeight=0;this.thmHeight=0;this.cTop=0;this.cBot=0;this.cWidth=0;this.fileLoaded=scrFileLoaded;this.scrollBy=scrScrollBy;this.thumbDown=scrThumbDown;this.setup=scrSetup;this.layout=scrLayout;}
var activeScr=null,scrOffset=0,winWidth,winHeight,scrFirstWidth=window.innerWidth,mainDiv,mainDiv2,mainDiv3,mainDiv4,minWinWidth=500,minWinHeight=300;
function getWidth(){if(window.innerWidth)return window.innerWidth;else return document.body.offsetWidth-2;}
function getHeight(){if(window.innerHeight)return window.innerHeight;else return document.body.offsetHeight-4;}
function getDivWidth(){return getWidth()-45;}
function getDivHeight(){return getHeight()-55;}
function getScrollX(){return getWidth()-29;}
function getScrollY(){return getHeight()-38;}
function getScrollHeight(){return getHeight()-70;}
var interval;
function initS(){
	//if(document.all&&((navigator.userAgent.indexOf("Mac")!=-1) ||(navigator.userAgent.indexOf("Macintosh")!=-1))&&val==1)window.history.go(0);
	//if(getWidth()>500&&getHeight()>300){
		
			//divScroll=getSty(divs[1][0]);
			//if(DOM||IE4)divScroll.clip='rect(0px 14px '+getScrollHeight()+'px 0px)';else if(NS4)divScroll.clip.bottom=getScrollHeight();
	//}
	//}
	mainDiv.setup();
	mainDiv2.setup();
	mainDiv3.setup();
	//document.getElementById('hauteurmobile').height=getHeight()-79;
}
mainDiv=new DHTMLScroller('mainDiv');
		with(mainDiv){
			divs[0]=new Array('mainContentDiv','198','41','161','52');
			divs[1]=new Array('scrollBar','362','47','11','40');
			divs[2]=new Array('scrollThumb','363','48','9','38');
			divs[3]=new Array('upArrows','363','38','9','9');
			divs[4]=new Array('downArrows','363','87','9','9');
		}
		
mainDiv2=new DHTMLScroller('mainDiv2');
		with(mainDiv2){
			divs[0]=new Array('mainContentDiv2','387','41','161','52');
			divs[1]=new Array('scrollBar2','552','47','11','40');
			divs[2]=new Array('scrollThumb2','552','48','9','38');
			divs[3]=new Array('upArrows2','552','38','9','9');
			divs[4]=new Array('downArrows2','552','87','9','9');
		}
		
mainDiv3=new DHTMLScroller('mainDiv3');
		with(mainDiv3){
			divs[0]=new Array('mainContentDiv3','577','41','161','52');
			divs[1]=new Array('scrollBar3','742','47','11','40');
			divs[2]=new Array('scrollThumb3','742','48','9','38');
			divs[3]=new Array('upArrows3','742','38','9','9');
			divs[4]=new Array('downArrows3','742','87','9','9');
		}
/*
mainDiv2=new DHTMLScroller('mainDiv2');
with (mainDiv2){
 divs[0] = new Array('mainContentDiv2', '128', '153', '120', '116');
 divs[1] = new Array('scrollBar2', '252', '169', '14', '84');
 divs[2] = new Array('scrollThumb2', '254', '', '10', '');
 divs[3] = new Array('upArrows2', '252', '153', '14', '16');
 divs[4] = new Array('downArrows2', '252', '253', '14', '16');
}
*/