var speed = 8;

function upScroll() {
	if (ua["dom"]) {
		var scrollobj = document.getElementById("inet_scroll");
		var contentheight = scrollobj.offsetWidth;
		if (window.upscrollvar) clearTimeout(upscrollvar)

		if (parseInt(scrollobj.style.top) < 0) {
			scrollobj.style.top = parseInt(scrollobj.style.top) + speed + "px";
		}
		upscrollvar = setTimeout("upScroll()",20);
	}
}

function downScroll() {
	if (ua["dom"]) {
		var scrollbox = document.getElementById("inet_right_main");
		var scrollobj = document.getElementById("inet_scroll");
		var boxheight = scrollbox.offsetHeight;
		var contentheight = scrollobj.offsetHeight;
		/*if (ua["iewin"]) {
			contentwidth -= 4;
		}*/

		if (window.downscrollvar) clearTimeout(downscrollvar)
		
		if (parseInt(scrollobj.style.top)+contentheight > boxheight) {
			scrollobj.style.top = parseInt(scrollobj.style.top) - speed + "px";
		}

		downscrollvar = setTimeout("downScroll()",20);
	}
}

function stopScroll() {
	if (ua["dom"]) {
		if (window.upscrollvar) clearTimeout(upscrollvar)
		if (window.downscrollvar) clearTimeout(downscrollvar)
	}
}