$(document).ready(function()
{
	// rounded corners //
	$(".rounded").corner("round 8px").parent().css("padding", "2px").corner("round 10px");

	// vertical slider //
	var visible_height = $("#event-schedule-body" ).height();
	$('#event-schedule-body').css('height', visible_height);
	var total_height = $("#dyncontent-schedule" ).height();
	var interval = 30;
	var offset = 0;
	var my_interval = null;
	$("#event-schedule-buttons .nextPage" ).mouseover(function(){
		my_interval = setInterval(function(){
			total_height = $("#dyncontent-schedule" ).height();
			if(total_height > visible_height)
			{
				if((0-offset) < (total_height-(interval*2)))
				{
					offset -= interval;
					$("#dyncontent-schedule").stop().animate({"marginTop": offset+"px"});
				}
			}
		}, 150);
	}).mouseout(function(){
		clearInterval(my_interval);
		$("#dyncontent-schedule").stop();
	});
	$("#event-schedule-buttons .prevPage" ).mouseover(function(){
		my_interval = setInterval(function(){
			if(total_height > visible_height)
			{
				if(offset < 0)
				{
					offset += interval;
					$("#dyncontent-schedule").stop().animate({"marginTop": offset+"px"});
				}
			}
		}, 150);
	}).mouseout(function(){
		clearInterval(my_interval);
		$("#dyncontent-schedule").stop();
	});

});
