<!--
var px = 1;//mehr=schneller
var timer;
var div = '';

function scrollDivVer(val)
{
	clearTimeout(timer);
	d=document.getElementById(div);
	y=d.scrollTop;
	y+=(val*px);
	if(y<=d.scrollHeight-d.offsetHeight+px&&y>=0-px)
	{
		d.scrollTop=y;
		timer=setTimeout('scrollDivVer('+val+')',50);
	}
	if(y<0||y>d.scrollHeight-d.offsetHeight)
	{
		clearTimeout(timer);
	}
}

function scrollDivHor(val)
{
	clearTimeout(timer);
	d=document.getElementById(div);
	x=d.scrollLeft;
	x+=(val*px);
	if(x<=d.scrollWidth-d.offsetWidth+px&&x>=0-px)
	{
		d.scrollLeft=x;
		timer=setTimeout('scrollDivHor('+val+')',50);
	}
	if(x<0||x>d.scrollWidth-d.offsetWidth)
	{
		clearTimeout(timer);
	}
}

function scrollDiv(name,pixel,direction)
{
	div = name;
	px = Math.abs(pixel);
	stepdirection = pixel / Math.abs(pixel);
	if (direction == 'v')
		scrollDivVer(stepdirection);
	else
		scrollDivHor(stepdirection);
}
//-->
