var sPr='prototype';function Reg(s,sP){var sRE='new RegExp(';sRE+=((s)?(sP)?'\''+s+'\',\''+sP+'\'':'\''+s+'\'':'')+')';return eval(sRE)}
function ToBool(a) { return Boolean(a); }function ToNumber(a) { return Number(a); }function ToString(a) { return String(a); }function ToTwoDigit(n){ var s=ToString(n);return(s.length<2)?'0'+s:ToString(s); }function GetType(a) { return typeof(a); }function IsString(a) { return GetType(a)=='string'; }function IsNumber(a) { return GetType(a)=='number'; }function IsObject(a) { return GetType(a)=='object'; }function IsFunction(a) { return GetType(a)=='function'; }
function Obj(){var a=arguments,o=new Object(),i;for(i=0;i<a.length;i+=2)o[a[i]]=a[i+1];return o}var aObj=Obj();function toString(){return'aObj[\''+this.id+'\']'}
b=Obj('ns4',ToBool(document.layers),'ie',ToBool(document.all),'dom',ToBool(document.getElementById));b.ns=ToBool(b.ns4||(b.dom&&!b.ie)),b.ieDom=ToBool(b.ie&&b.dom),b.nsDom=ToBool(b.ns&&b.dom);String.prototype.mask=function(){return this.replace(/\S/g,'*')};
Function.prototype.toName=function(){var sF=ToString(this.valueOf());sF=sF.substr(sF.indexOf('function'));return(sF&&sF.length>8&&sF.charAt(8)==' ')?sF.substring(9,sF.indexOf('(')):null};
Function.prototype.addProto=function(){var a=arguments,nL=a.length,oB,oP,bM;for(var i=0;i<nL;i++){if(IsFunction(oB=a[i])){oP=oB[sPr],bM=true;for(var sP in oP)bM=false,this[sPr][sP]=oP[sP];if(bM)this[sPr][oB.toName()]=oB}}};
if(!Function.call)Function.prototype.call=function(o){var a=arguments;o.tB=this;o.tB(a[1],a[2],a[3],a[4],a[5],a[6],a[7],a[8],a[9],a[0],a[11],a[12],a[13],a[14],a[15]);delete o.tB};if(!window.aOnLoad){window.aOnLoad=[];aOnLoad[aOnLoad.length]=window.onload;window.onload=function(){window.loaded = true;for(var i=0;i<aOnLoad.length;i++)if(aOnLoad[i])aOnLoad[i]();window.loaded = true;}}
function addOnLoad(f) {if (IsFunction(f)) aOnLoad[aOnLoad.length] = f;}Number.sF=['th','st','nd','rd'];Number.prototype.ToPosition = function(){var s=ToString(this),n=s.length,s1=s.charAt(n-1),s2=s.charAt(n-2);return(this>0)?this+Number.sF[(s2!='1'&&s1>0&&s1<4)?ToNumber(s1):0]:this};var screenWidth, screenHeight;with (screen) screenWidth=availWidth || width, screenHeight=availHeight || height;if (b.ns){if(b.ns4){
GetDivs=function(aL){if(aL){var i,nL=aL.length,oL,aT,sId,aAll;for(i=0;i<nL;i++){if(!document.all[(sId=(oL=aL[i]).id)]){aT=document.allTags[(oL.tagName='div')],aAll=document.all;aT[aT.length]=aAll[sId]=aAll[aAll.length++]=oL.style=oL}GetDivs(oL.document.layers)}}};
GetImages = function (aI) {
	if (aI) {
		var i,nL=aI.length,oL,aT,sId,aAll;
		for(i=0;i<nL;i++){
			sId=(oL=aI[i]).name;
			if(sId && !document.all[(sId)]){
				aT=document.allTags[(oL.tagName='img')],aAll=document.all;
				aT[aT.length]=aAll[sId]=aAll[aAll.length++]=oL.style=oL
			}
		}
	}
}
ToDOMStandar=function(){
document.all=Obj('length',0);
document.allTags=Obj('form',[],'div',[],'img',[]);
document.getElementById=function(sId){return this.all[sId]||this.images[sId]||null};
document.getElementsByTagName=function(sTagName){return this.allTags[sTagName]||null};
//GetImages(document.images);
GetDivs(document.layers);
var nL=document.all.length,i,ii,nL,aF,nFL,aI,nIL,oElm,sName,aDocF=document.forms,aDocI=document.images,oF_tmp;
for(i=0;i<nL;i++){oL=document.all[i],aF=oL.document.forms,nFL=aF.length,aI=oL.document.images,nIL=aI.length;
for(ii=0;ii<nFL;ii++){aDocF[aDocF.length]=oElm=aF[ii],sName=oElm.name;if(!aDocF[sName]){aDocF[sName]=oElm;}
else{oF_tmp=aDocF[sName];
if(oF_tmp.name){aDocF[sName]=[];aDocF[sName][aDocF[sName].length]=oF_tmp;}aDocF[sName][aDocF[sName].length]=oElm;}}
for(ii=0;ii<nIL;ii++){oElm=aI[ii],sName=oElm.name;if(!aDocI[sName])aDocI[aDocI.length]=aDocI[sName]=oElm}}};

aOnLoad=new Array(function(){ToDOMStandar()}).concat(aOnLoad);}}function TempDiv(o){this.elm=o;if(o){this.style=o.style;if(!b.ns4)o.style.overflow='hidden';else o.sBgC=this.elm.document.bgColor;return aObj[this.id=o.id]=this}else return null}
var tempDivProto=TempDiv['prototype'];tempDivProto.setXY=function(nX,nY){this.setX(nX),this.setY(nY)};
if (b.ie && !b.dom) {tempDivProto.getX=tempDivProto.getAbsX=function(){return(this.elm)?this.elm.offsetLeft:0};tempDivProto.getY=tempDivProto.getAbsY=function(){return(this.elm)?this.elm.offsetTop:0};tempDivProto.getW=function(){return(this.elm)?this.elm.offsetWidth:0};tempDivProto.getH=function(){return(this.elm)?this.elm.offsetHeight:0};tempDivProto.getCW=function(){return(this.elm)?this.elm.scrollWidth:0};tempDivProto.getCH=function(){return(this.elm)?this.elm.scrollHeight:0};tempDivProto.getV=function(){return(this.style)?ToBool(this.style.visibility!='hidden'):false};tempDivProto.setX=function(n){if(this.style)this.style.pixelLeft=(IsNumber(n))?n:null};tempDivProto.setY=function(n){if(this.style)this.style.pixelTop=(IsNumber(n))?n:null};tempDivProto.setW=function(n){if(this.style)this.style.pixelWidth=(IsNumber(n))?n:null};tempDivProto.setH=function(n){if(this.style)this.style.pixelHeight=(IsNumber(n))?n:null};tempDivProto.setV=function(b){if(this.style)this.style.visibility=(ToBool(b)&&b)?'inherit':'hidden'};} else if (b.ieDom) {	
tempDivProto.getX=function(){return(this.elm)?this.elm.offsetLeft:0};
tempDivProto.getY=function(){return(this.elm)?this.elm.offsetTop:0};tempDivProto.getAbsX=function(){var n=0,oE=this.elm,sN;while(oE&&(oE=oE.parentNode)&&(sN=oE.nodeName)!='HTML')n+=(sN!='TD'&&sN!='TR')?oE.offsetLeft:1;return n};
tempDivProto.getAbsY=function(){var n=0,oE=this.elm,sN;while(oE&&(oE=oE.parentNode)&&(sN=oE.nodeName)!='HTML')n+=(sN!='TD'&&sN!='TR')?oE.offsetTop:1;return n};tempDivProto.getW=tempDivProto.getCW=function(){return(this.elm)?this.elm.offsetWidth:0};tempDivProto.getH=tempDivProto.getCH=function(){return(this.elm)?this.elm.offsetHeight:0};tempDivProto.getV=function(){return(this.style)?ToBool(this.style.visibility!='hidden'):false};tempDivProto.setClass=function(sC){if(sC&&this.elm)this.elm.className=sC};tempDivProto.setX=function(n){if(this.style)this.style.left=(IsNumber(n))?n+'px':''};tempDivProto.setY=function(n){if(this.style)this.style.top=(IsNumber(n))?n+'px':''};tempDivProto.setW=function(n){if(this.style)this.style.width=(IsNumber(n))?n+'px':''};tempDivProto.setH=function(n){if(this.style)this.style.height=(IsNumber(n))?n+'px':''};tempDivProto.setV=function(b){if(this.style)this.style.visibility=(ToBool(b)&&b)?'inherit':'hidden'};}else if(b.ns4){tempDivProto.getX=function(){return(this.elm)?this.elm.left:0};tempDivProto.getY=function(){return(this.elm)?this.elm.top:0};tempDivProto.getAbsX=function(){return(this.elm)?this.elm.pageX:0};tempDivProto.getAbsY=function(){return(this.elm)?this.elm.pageY:0};tempDivProto.getW=function(){var e=this.elm,n=0;if(e){n=e.clip.width;if(!IsNumber(n))n=e.document.width||0}return n};tempDivProto.getCW=function(){var e=this.elm,n=0;if(e){n=e.document.width||0}return n};tempDivProto.getH=function(){var e=this.elm,n=0;if(e){n=e.clip.height;if(!IsNumber(n))n=e.document.height||0}return n};tempDivProto.getCH=function(){var e=this.elm,n=0;if(e){n=e.document.height||0}return n};tempDivProto.getC=function(){var oE=this.elm,a=[];if(oE){a[0]=oE.clipTop,a[1]=oE.clipRight,a[2]=oE.clipBottom,a[3]=oE.clipLeft}return a};tempDivProto.getV=function(){return(this.elm)?ToBool(this.elm.visibility!='hide'):false};tempDivProto.setX=function(n){if(this.elm)this.elm.left=(IsNumber(n))?n:null};tempDivProto.setY=function(n){if(this.elm)this.elm.top=(IsNumber(n))?n:null};tempDivProto.setW=function(n){if(this.elm)this.elm.clip.width=(IsNumber(n))?n:null};tempDivProto.setH=function(n){if(this.elm)this.elm.clip.height=(IsNumber(n))?n:null};tempDivProto.setC=function(nT,nR,nB,nL){var oE=this.elm;if(oE){if(nT&&IsObject(nT)&&nT.length==4)nR=nT[1],nB=nT[2],nL=nT[3],nT=nT[0];oE.clip.top=nT||0,oE.clip.right=nR||0,oE.clip.bottom=nB||0,oE.clip.left=nL||0}};tempDivProto.setV=function(b){if(this.elm)this.elm.visibility=(ToBool(b)&&b)?'inherit':'hide'};} else if (b.nsDom) {tempDivProto.getX=function(){return(this.elm)?this.elm.offsetLeft:0};tempDivProto.getY=function(){return(this.elm)?this.elm.offsetTop:0};tempDivProto.getAbsX=function(){var n=0,oE=this.elm,sN;while(oE&&(oE=oE.parentNode)&&(sN=oE.nodeName)!='HTML')n+=(sN!='TD'&&sN!='TR')?oE.offsetLeft:1;return n};tempDivProto.getAbsY=function(){var n=0,oE=this.elm,sN;while(oE&&(oE=oE.parentNode)&&(sN=oE.nodeName)!='HTML')n+=(sN!='TD'&&sN!='TR')?oE.offsetTop:1;return n};tempDivProto.getW=tempDivProto.getCW=function(){return(this.elm)?this.elm.offsetWidth:0};tempDivProto.getH=tempDivProto.getCH=function(){return(this.elm)?this.elm.offsetHeight:0};tempDivProto.getV=function(){return(this.style)?ToBool(this.style.visibility!='hidden'):false};tempDivProto.setClass=function(sC){if(sC&&this.elm)this.elm.className=sC};tempDivProto.setX=function(n){if(this.style)this.style.left=(IsNumber(n))?n+'px':''};tempDivProto.setY=function(n){if(this.style)this.style.top=(IsNumber(n))?n+'px':''};tempDivProto.setW=function(n){if(this.style)this.style.width=(IsNumber(n))?n+'px':''};tempDivProto.setH=function(n){if(this.style)this.style.height=(IsNumber(n))?n+'px':''};tempDivProto.setV=function(b){if(this.style)this.style.visibility=(ToBool(b)&&b)?'inherit':'hidden'};}

function Div(sId){var o=document.getElementById(sId);if(!o)return null;TempDiv.call(this,o);return this}Div.addProto(TempDiv,toString);
//Scroller=new Object();Scroller.go	= function(id, type, returning) {var sSCId	= 'ScrollContainer' + id;var sSId	= 'Scroll' + id;var oSC	= new Div(sSCId);var oS	= new Div(sSId);if (oSC && oS) {if (type != 'S') {if (!returning) Scroller.on = true;if (Scroller.on) {var nInc = 6, nS = oS.getX() +((type == 'R')? -(nInc) : nInc);if ((type == 'R' &&(oS.getW()+nS+nInc) >= oSC.getW()) || (type == 'L' && nS <=0)) {oS.setX(nS);setTimeout('Scroller.go(\'' +id + '\', \'' + type + '\', true)', 20);} else Scroller.on	= false;}} else Scroller.on	= false;}};Scroller.on	= false;

Scroller=new Object();
	Scroller.go	= function(id, type, returning) {
		var sSCId	= 'ScrollContainer' + id;
		var sSId	= 'Scroll' + id;
		var oSC	= new Div(sSCId);
		var oS	= new Div(sSId);
		if (oSC && oS) {
			if (type != 'S') {
				if (!returning) Scroller.on = true;
				if (Scroller.on) {
					var nInc = 1, nS = oS.getX() +((type == 'R')? -(nInc) : nInc);
					nY = oS.getY() + ((type == 'B')? -(nInc) : nInc);
					
					if ((type == 'R' &&(oS.getW()+nS+nInc) >= oSC.getW()) || (type == 'L' && nS <=0)) {
						oS.setX(nS);
						setTimeout('Scroller.go(\'' +id + '\', \'' + type + '\', true)', 20);
					} else if ((type == 'B' &&(oS.getH()+nY+nInc) >= oSC.getH()) || (type == 'T' && nY <=0)) {
						oS.setY(nY);
						setTimeout('Scroller.go(\'' +id + '\', \'' + type + '\', true)', 20);
					} else Scroller.on	= false;
				}
			} else Scroller.on	= false;
		}
	};Scroller.on	= false;
function TgI(sId,sSrc){var o=document.images;if(o&&o[sId])o[sId].src=sSrc};Preload=Obj('images',[],'imagesId',Obj(),'loadCount',0,'id',0,'comp',false,'onInc',null,'onComp',null);Preload.incImg=function(oIE){oIE.loaded=true;var o=Preload;o.loadCount++;o.length=o.images.length;o.percent=Math.round((o.loadCount/o.length)*100);if(o.onInc)o.onInc();if(o.loadCount==o.length)o.doComp()};Preload.doComp=function(){var o=Preload;o.comp=true;if(o.onComp)o.onComp()};Preload.setOnInc=function(fF){Preload.onInc=(IsFunction(fF))?fF:null};Preload.setOnComp=function(fF){Preload.onComp=(IsFunction(fF))?fF:null};Preload.getById=function(sId){var o=Preload;return o.images[o.imagesId[sId]]||null};Preload.getByIndex=function(nI){return Preload.images[nI]||null};Preload.getBySrc=function(sS){var oImg=null,aImages=Preload.images,nL=aImages.length,i;for(i=0;i<nL;i++){if(aImages[i].src==sS)oImg=aImages[i]}return oImg};Preload.addImg=function(sId,sSrc){var o=Preload,oI=new Image(),aI=o.images;sId=(sId&&IsString(sId))?sId:'PImg_'+(o.id++),sSrc=(IsString(sSrc))?sSrc:'';oI.onload=function(){Preload.incImg(this)};oI.sSrc=sSrc;aI[o.imagesId[oI.sId=sId]=aI.length]=oI;};Preload.start=function(){var oI,aI=Preload.images,nL=aI.length,i;for(i=0;i<nL;i++){oI=aI[i];oI.src=oI.sSrc;}};Preload.TgI=function(sIN,sId){TgI(sIN,Preload.getById(sId).src)};Preload.setAlt=function(sId,sAlt){setAlt(sId,sAlt)};

