var time;

function startMarquee(divId)
{
	time=setTimeout("scrollMarquee('innerScroll"+divId+"',-1)",50);
}

function scrollMarquee(divId,direction)
{
	speed = 50;
	if(parseInt($(divId).style.left) < - parseInt($(divId).offsetWidth - 135))
	{
		direction = 1;
		speed = 1500;
	}
	else if(parseInt($(divId).style.left) > 0)
	{
		direction = -1;
		speed = 1500;
	}
	
	$(divId).style.left = (parseInt($(divId).style.left) + direction) + "px";
	time=setTimeout("scrollMarquee('"+divId+"',"+direction+")",speed)		
}

function restoreMarquee(divId)
{
	clearTimeout(time);
	$('innerScroll'+divId).style.left = 0 + "px";
}

function showTooltip(value)
{
	var visibility = "hidden";
	if(value)
	{
		visibility = "visible";
	}
	
	$('tooltipWrapper').style.visibility = visibility;
}