


var currslid = 0;
var slidint;
var focpic;
//function setfoc(id){
//	document.getElementById("focpic").src = picarry[id];
//	document.getElementById("foclnk").href = lnkarry[id];
//	currslid = id;
//	focpic=document.getElementById("focpic");
//	for(i=0;i<3;i++){
//		document.getElementById("tmb"+i).className = "thubpic";
//	};
//	document.getElementById("tmb"+id).className ="thubpiccur";
//	focpic.filters[0].Apply();
//	focpic.filters[0].transition=23;
//	focpic.filters[0].Play();
//	stopit();
//}

function setfoc1(id){
	document.getElementById("focpic1").src = picarry1[id];
	document.getElementById("foclnk1").href = lnkarry1[id];
	currslid = id;
	focpic=document.getElementById("focpic1");
	for(i=0;i<3;i++){
		document.getElementById("tmb1"+i).className = "thubpic";
	};
	document.getElementById("tmb1"+id).className ="thubpiccur";
	focpic.filters[0].Apply();
	focpic.filters[0].transition=23;
	focpic.filters[0].Play();
	stopit();
}
function setfoc2(id){
	document.getElementById("focpic2").src = picarry2[id];
	document.getElementById("foclnk2").href = lnkarry2[id];
	currslid = id;
	focpic=document.getElementById("focpic2");
	for(i=0;i<3;i++){
		document.getElementById("tmb2"+i).className = "thubpic";
	};
	document.getElementById("tmb2"+id).className ="thubpiccur";
	focpic.style.visibility = "hidden";
	focpic.filters[0].Apply();
	if (focpic.style.visibility == "visible") {
		focpic.style.visibility = "hidden";
		focpic.filters.revealTrans.transition=23;
	}
	else {
		focpic.style.visibility = "visible";
		focpic.filters[0].transition=23;
	}
	focpic.filters[0].Play();
	stopit();
}

function playnext(){
	if(currslid==2){
		currslid = 0;
	}
	else{
		currslid++;
	};
	//setfoc(currslid);
	playit();
}
function playit(){
	slidint = setTimeout(playnext,4500);
}
function stopit(){
	clearTimeout(slidint);
	}
//window.onload = function(){
//	playit();
//}


/* ------------------------------------------------------------------------
	www.lanrentuku.com
------------------------------------------------------------------------- */

var n=0;
var showNum = document.getElementById("num");
function Mea(value){
	n=value;
	if(n==0){
		document.getElementById("pc_1").style.display="none";
		//document.getElementById("pc_2").style.display="none";
		document.getElementById("pc_0").style.display="block";
		document.getElementById("a0").className='act';
		document.getElementById("a1").className='nor1';
		//document.getElementById("a2").className='nor2';
	}else if(n==1){
		//document.getElementById("pc_2").style.display="none";
		document.getElementById("pc_0").style.display="none";
		document.getElementById("pc_1").style.display="block";
		document.getElementById("a0").className='nor';
		document.getElementById("a1").className='act1';
		//document.getElementById("a2").className='nor2';
	}else if(n==2){
		document.getElementById("pc_1").style.display="none";
		document.getElementById("pc_0").style.display="none";
		//document.getElementById("pc_2").style.display="block";
		document.getElementById("a0").className='nor';
		document.getElementById("a1").className='nor1';
		//document.getElementById("a2").className='act2';
	}
}
function clearAuto(){clearInterval(autoStart)}
function setAuto(){autoStart=setInterval("auto(n)", 3000);
clearAuto();}
function auto(){
	n++;
	if(n>2)n=0;
	Mea(n);
} 
function sub(){
	n--;
	if(n<0)n=2;
	Mea(n);
} 
setAuto(); 

