var SlideShow_Lite=null;
var SlideShow_Left=0;
var SlideShow_Interval=null;
var Slide_Show_Speed=22;
function SlideShow_Lite_Init(id){		
	div=document.getElementById(id);
	div.style.overflow='hidden';
//	if (document.location.hash){
//		var SlideShow_Focus=document.getElementById(document.location.hash.substr(1));
//		if (SlideShow_Focus&&SlideShow_Focus.parentNode.id==id){
//			while(SlideShow_Focus=SlideShow_Focus.)
//			SlideShow_Focus.parentNode.scrollLeft=SlideShow_Focus.offsetLeft;
//		}
//	}
	var slideBody=[];
	maxHeight=0;
	for (i=0; i<div.childNodes.length; i++){		
		if (!div.childNodes[i].tagName) continue;
		for (j=0; j<div.childNodes[i].childNodes.length;j++){			
			if (div.childNodes[i].childNodes[j].className=='slidebody'){
				
				if (div.childNodes[i].childNodes[j].clientHeight>maxHeight) maxHeight=div.childNodes[i].childNodes[j].clientHeight;
				slideBody[slideBody.length]=div.childNodes[i].childNodes[j];
			}
		}
	}
	for (i=0; i<slideBody.length; i++){
	//	slideBody[i].style.height=maxHeight+'px';
	}
	//alert(maxHeight);
	//div.style.height=maxHeight+'px';
}

function SlideShow_Lite_Fwd(id){
	
	if (SlideShow_Interval) return false;
	SlideShow_Lite=document.getElementById(id);
	
	if (!SlideShow_Lite) return false;
	SlideShow_Left=parseInt(SlideShow_Lite.offsetLeft)+parseInt(SlideShow_Lite.clientWidth);
	SlideShow_Interval=setInterval(_SlideShow_List_Fwd,2);
	return false;
}

function _SlideShow_List_Fwd(){
	Left=parseInt(SlideShow_Lite.parentNode.scrollLeft);
	Left=Left+Slide_Show_Speed;	
	if (Left>SlideShow_Left){
		
		Left=SlideShow_Left;		
		clearInterval(SlideShow_Interval);
		SlideShow_Interval=null;
	}	
	SlideShow_Lite.parentNode.scrollLeft=Left;	
}

function SlideShow_Lite_Back(id){
	if (SlideShow_Interval) return false;
	SlideShow_Lite=document.getElementById(id);
	
	if (!SlideShow_Lite) return false;
	SlideShow_Left=parseInt(SlideShow_Lite.offsetLeft)-parseInt(SlideShow_Lite.clientWidth);
	SlideShow_Interval=setInterval(_SlideShow_Lite_Back,1);
	return false;
}

function _SlideShow_Lite_Back(){
	Left=parseInt(SlideShow_Lite.parentNode.scrollLeft);
	Left=Left-Slide_Show_Speed;
	if (Left<SlideShow_Left){
		Left=SlideShow_Left;		
		clearInterval(SlideShow_Interval);
		SlideShow_Interval=null;
	}	
	SlideShow_Lite.parentNode.scrollLeft=Left;	
}