var mnpMenuTop = null;
var mnpMenuKill = null;
var mnpMenuPopup = null;
var mnpMenuUrl = null;
var mnpMenuParent = null;
var mnpMenuScrollTimer = null;
var mnpMenuShadows = new Array();
var mnpMenuDirSave = "LTR";
var mnpMenuCTSave = false;
var mnpMenuRenderStart = null;
var mnpMenuShadowsEnabled = true;
window.attachEvent("onload", mnpMenuInit);
function mnpMenuInit()
{
try
{
mnpMenuDirSave = mnpMenuDir();
mnpMenuCTSave = mnpMenuCT();
}
catch(e)
{
return;
}
mnpMenuTop = document.getElementById("mnpMenuTop");
mnpMenuUrl = mnpMenuTop.getAttribute("url");
mnpMenuParent = mnpMenuTop.getAttribute("parent");
mnpMenuAttach(mnpMenuTop);
}
function mnpPage(label, url, target, menu, linkID)
{
this.label = label;
this.url = url;
this.target = target;
this.menu = menu;
this.linkID = linkID;
}
function mnpLabel(label)
{
this.label = label;
}
function mnpMenuEnter()
{
if (mnpMenuKill)
{
window.clearTimeout(mnpMenuKill);
mnpMenuKill = null;
}
}
function mnpMenuLeave()
{
mnpMenuKill = window.setTimeout("mnpMenuKiller()", 200);
}
function mnpMenuKiller()
{
mnpKillMenu(mnpMenuTop.getAttribute("currentMenu"));
mnpMenuTop.removeAttribute("currentMenu");
}
function mnpMenuAttach(el)
{
el.attachEvent("onmouseenter", mnpMenuEnter);
el.attachEvent("onmouseleave", mnpMenuLeave);
var divs = el.getElementsByTagName("DIV");
for (var i=0; i < divs.length; i++)
{
var div = divs.item(i);
if (div.className == "mnpMenuRow")
{
div.attachEvent("onmouseenter", mnpMenuMouseover);
div.attachEvent("onmouseleave", mnpMenuMouseout);
div.attachEvent("onmousedown", mnpMenuMousedown);
div.attachEvent("onmouseup", mnpMenuMouseup);
div.setAttribute("save-background", div.style.background);
div.setAttribute("save-border", div.style.borderColor);
var a = div.getElementsByTagName("A");
if (a.length > 0)
{
var a0 = a[0];
if (a0.getAttribute("aoff"))
a0.outerHTML = a0.innerHTML;
else
{
div.setAttribute("status", a0.href);
div.attachEvent("onclick", mnpMenuClick);
}
}
if (div.getAttribute("menu"))
{
var imgs = div.getElementsByTagName("IMG");
if (imgs.length > 0)
{
var img = imgs[0];
img.style.visibility = "visible";
}
else
{
var x;
if (mnpMenuDirSave == "LTR")
x = (div.offsetWidth - 10) + "px";
else if (mnpMenuTop.contains(div))
x = "4px";
else
x = "6px";
var img = "
";
div.insertAdjacentHTML("afterBegin", img);
}
}
}
}
}
function mnpMenuClick()
{
var div = window.event.srcElement;
var a = div.getElementsByTagName("A");
if (a.length == 0) return;
if (window.event.shiftKey)
{
var target = a[0].target;
a[0].target = "_new";
a[0].click();
a[0].target = target;
}
else
a[0].click();
}
function mnpKillMenu(id)
{
if (id == null) return;
var menu = document.getElementById(id);
var current = menu.getAttribute("currentMenu");
if (current)
{
mnpKillMenu(current);
menu.removeAttribute("currentMenu");
}
var temp = mnpMenuShadows[id];
if (temp)
{
var i;
for (i=0; i