

	var stop = true;
	var count = 0;
	var interval = ie ? 30 : 20;
	var pix = ie ? 2 : 3;

	function slideUp(id){
	
		if( stop ){
			return;
		}	
		
		var slidingDiv = document.getElementById(id);
		var area = document.getElementById('webcam');
	
		var thumPos = slidingDiv.style.top.replace('px','')/1;
		var areaPos = area.style.top.replace('px','')/1;	
	
		var pos = slidingDiv.style.top.replace('px','')/1;
		
		if ( thumPos < areaPos )
		{
			slidingDiv.style.top = (pos + pix) + "px";
			setTimeout('slideUp("' + id + '")', interval);
		}
	}
	
	function slideDown(id){
		
		if( stop ){
			return;
		}
		
		var slidingDiv = document.getElementById(id);
		var area = document.getElementById('webcam');
		
		var thumPos = slidingDiv.style.top.replace('px','')/1 + slidingDiv.offsetHeight;
		var areaPos = area.style.top.replace('px','')/1 + area.offsetHeight + 0;
	
		var pos = slidingDiv.style.top.replace('px','')/1;
		
		if ( thumPos > areaPos )
		{
			
			slidingDiv.style.top = (pos - pix) + "px";
			setTimeout('slideDown("' + id + '")', interval);
		}		
	}
	
	function Start( direction, id ){
		
		if( stop == false ){
						
			return;
		}
		
		stop = false;
		
		if( direction == 1 ){
			
			slideDown(id);
		}
		else{
			
			slideUp(id);
		}	
	}
	
	function Stop(){
		
		stop = true;
	}
