/* 
	Copyright (c) 2005-2008 Metablocks, Inc, Metablocks, Ltd. and their affiliates. 
	This software is under non-exclusive licensed to the party using it. 
	For more information contact: info@metablocks.com
	The software cannot reused without permission. All Rights Reserved.
	
	Do not remove this copyright notice.
*/

var gtvt_tooltip={};
gtvt_tooltip.show=function  (e, obj, id)
{
	var posx = 0;
	var posy = 0;

	if (!e)
		e = window.event;

	if (e.pageX || e.pageY)
	{
		posx = e.pageX;
		posy = e.pageY;
	}
	else if (e.clientX || e.clientY)
	{
		if (document.documentElement && document.documentElement.scrollTop)
		{
			theTop = document.documentElement.scrollTop;
			theLeft = document.documentElement.scrollLeft;
		}
		else if (document.body)
		{
			theTop = document.body.scrollTop
			theLeft = document.body.scrollLeft;
		}

		posx = e.clientX + theLeft;
		posy = e.clientY + theTop;
	}

	// If you resize graphic, you need to modify this
	
	var ie4=(document.all)? true:false;

	if (navigator.userAgent.indexOf("MSIE") > -1)
	{
		posx += 10;
	} /* Start of newly added code */
	else if (navigator.userAgent.indexOf("Apple") > -1)
	{
		posx += 15;
	}
	else if (navigator.userAgent.indexOf("Mozilla") > -1)	
	{
		posx += 90;
	} /* End of newly added code */
	else
		posx += 90;
		
	posy -= 20;

	var elem = document.getElementById(id);
	elem.style.display = "block";
	elem.style.top = posy + "px";
	elem.style.left = posx + "px";
}

gtvt_tooltip.hide=function (id)
{
	document.getElementById(id).style.display = "none";
}
