var main_timer;
var x = 1;
function main_switch()
{
	hot_news_poster(x);
	if(x<4)
	{
		x++;
	}
	else
	{
		x = 0;
	}
}

var dest;
var step;
var timer;
var moving = false;
function hot_news_current_top()
{
	return parseInt(document.getElementById('flashInternal').style.marginTop);
}
function hot_news_poster(index_number)
{
	dest = -(index_number * 240);
	if(hot_news_current_top() > dest)
	{
		step = -20;
	}
	else
	{
		step = 20;
	}
	timer = setInterval("hot_news_poster_go()",10);
	moving = true;
}
function hot_news_poster_go()
{
	var obj = document.getElementById('flashInternal');
	if((hot_news_current_top() - dest) / -step < 1)
	{
		obj.style.marginTop = dest + "px";
		clearInterval(timer);
		moving = false;
	}
	else
	{
		obj.style.marginTop = (hot_news_current_top() + step) + "px";
	}
}
function set_current()
{
	var i=0;
	for(i=0;i<5;i++)
	{
		var obj_id = "poster_title_" + i;
		// set obj to unactive
	}
	//set current to active
}