function mozEvent_getCursor(e) {
  window.event.clientX = e.pageX;
  window.event.clientY = e.pageY;
  window.event.x = e.layerX;
  window.event.y = e.layerY;
  window.event.screenX = e.screenX;
  window.event.screenY = e.screenY;
  if (routeEvent(e) == false) 
  {
    return false;
  } 
  else 
  {
    return true;
  }
}

function DictionaryWord_Render() 
{
	out="";
	out+="<table cellpadding=0 cellspacing=0 width=158 bgcolor=#FFFFFF border=0>";
	out+="<tr><td rowspan=4 bgcolor=#333333><img src=http://a840.g.akamai.net/7/840/614/b191c6827273aa/www.overture.com/images/shared/x.gif alt='' width=1 height=1></td><td colspan=3 bgcolor=#333333><img src=http://a840.g.akamai.net/7/840/614/b191c6827273aa/www.overture.com/images/shared/x.gif alt='' width=58 height=1></td><td rowspan=4 bgcolor=#333333><img src=http://a840.g.akamai.net/7/840/614/b191c6827273aa/www.overture.com/images/shared/x.gif alt='' width=1 height=1></td></tr>";
	out+="<tr><td bgcolor=#FF6633><img src=http://a840.g.akamai.net/7/840/614/b191c6827273aa/www.overture.com/images/shared/x.gif alt='' width=5 height=1></td><td height=16 bgcolor=#FF6633 align=center><font face=verdana,arial,sans-serif size=1 color=#FFFFFF style='font-size=10px; font-weight:bold;'><b>Quick Help</b></font></td><td bgcolor=#FF6633><img src=http://a840.g.akamai.net/7/840/614/b191c6827273aa/www.overture.com/images/shared/x.gif alt='' width=5 height=1></td></tr>";
	out+="<tr><td><img src=http://a840.g.akamai.net/7/840/614/b191c6827273aa/www.overture.com/images/shared/x.gif alt='' width=5 height=1></td><td><font face=verdana,arial,sans-derif size=1 style='font-size:10px; font-weight:bold;'>&nbsp;<br><b>"+this.Word+"</b></font></td><td><img src=http://a840.g.akamai.net/7/840/614/b191c6827273aa/www.overture.com/images/shared/x.gif alt='' width=5 height=1></td></tr>";
	out+="<tr><td><img src=http://a840.g.akamai.net/7/840/614/b191c6827273aa/www.overture.com/images/shared/x.gif alt='' width=5 height=1></td><td><font face=verdana,arial,sans-derif size=1 style='font-size:10px;'>&nbsp;<br>"+this.Meaning+"&nbsp;<p></font></td><td><img src=http://a840.g.akamai.net/7/840/614/b191c6827273aa/www.overture.com/images/shared/x.gif alt='' width=5 height=1></td></tr>"
	out+="<tr><td colspan=5 bgcolor=#333333><img src=http://a840.g.akamai.net/7/840/614/b191c6827273aa/www.overture.com/images/shared/x.gif alt='' width=58 height=1></td></tr>";
	out+="</table><br>";
	return out;
}

function DictionaryWord ()
{
	this.Word = '';
	this.Meaning = 'No help is currently available at present for this word.'
	this.Render = DictionaryWord_Render;
}

function Dictionary_Find (w) 
{
	for (var i=0; i<this.Count; i++) {
		if (this.ItemList[i].Word==w) 
		{
			return this.ItemList[i];
		}
	}
	tItem = new DictionaryWord()
	tItem.Word = w;
	return tItem;  
}

function Dictionary_Populate () 
{
	this.ItemList[0].Word = "interchangeable";
	this.ItemList[0].Meaning = "An all-in-one eyewear kit provides cool looking sunglasses for those casual activities and goggles for those high speed activities.";
}

function Dictionary ()
{
	this.Count = 1;
	this.ItemList = new Array();
	for (var i=0; i<this.Count; i++) {
		this.ItemList[i] = new DictionaryWord();
	}
	this.Find  = Dictionary_Find;
	this.Populate = Dictionary_Populate;
}

var oDictionary = null;
if (!document.all)
{
	window.onmouseover = mozEvent_getCursor;
	window.onmouseout = mozEvent_getCursor;
	window.onclick = mozEvent_getCursor;
	window.ondblclick = mozEvent_getCursor;
	window.event = new Object;
}

function ShowMeaning (w) 
{
	if (oDictionary==null) 
	{
		oDictionary = new Dictionary();
		oDictionary.Populate();
	}
	
	if (w==null) 
	{
		if (document.getElementById)
		{
			frm = document.getElementById("quick_help");
			evt=window.event;
			frm.style.visibility="hidden";
		}
	}

	if (w!=null)
	{
		result = oDictionary.Find(w).Render();
		if (document.getElementById)
		{
			frm = document.getElementById("quick_help");
			evt=window.event;
			if (document.all)
			{
				frm.style.top = evt.y + parseInt(document.body.scrollTop);
				frm.style.left = evt.x + parseInt(document.body.scrollLeft);
				if (navigator.platform.indexOf('MacPPC') > -1)
				{
					frm.style.top = evt.y + parseInt(document.body.scrollTop) - 130;                 
					frm.style.left = evt.x + parseInt(document.body.scrollLeft) - 230;   
				}
			} 
			else
			{
				frm.style.top = evt.clientY;
				frm.style.left = evt.clientX; 
			}
			frm.style.visibility="visible";
			frm.innerHTML=result;  
		}
		else 
		{   
			if(!NN6 && document.quick_help)
			{
				if (parseInt(window.pageYOffset) > 400) 
					document.quick_help.top = parseInt (pageYOffset) + 30; 
				else 
					document.quick_help.top = 400; 	
				document.quick_help.visibility="show";
				document.quick_help.document.open();
				document.quick_help.document.write(""+result+"");
				document.quick_help.document.close();
			} 
		}       
	}
}