// JavaScript Document
// the number you pass to initLeft doesn't matter since it will get changed onactivate
//var myMenu1 = new ypSlideOutMenu("menu1", "down", 0, 0, 180, 200);
var myMenu2 = new ypSlideOutMenu("menu2", "down", 0, 0, 180, 200);
var myMenu3 = new ypSlideOutMenu("menu3", "down", 0, 0, 180, 200);
var myMenu4 = new ypSlideOutMenu("menu4", "down", 0, 0, 180, 200);
//var myMenu5 = new ypSlideOutMenu("menu5", "down", 0, 0, 180, 200);
var myMenu6 = new ypSlideOutMenu("menu6", "down", 0, 0, 180, 200);
var path = "";
/*
if(document.URL.indexOf("/pr/") > -1 || document.URL.indexOf("/ner/") > -1)
	path = "../";
hdrmenu1_off = new Image();
hdrmenu1_off.src = path+"images/nav-subscribe-ner-off.gif";
hdrmenu2_off = new Image();
hdrmenu2_off.src = path+"images/nav-about-adp-report-off.gif";
hdrmenu3_off = new Image();
hdrmenu3_off.src = path+"images/nav-analysis-february-off.gif";
hdrmenu4_off = new Image();
hdrmenu4_off.src = path+"images/nav-resources-off.gif";
hdrmenu5_off = new Image();
hdrmenu5_off.src = path+"images/nav-media-off.gif";
hdrmenu6_off = new Image();
hdrmenu6_off.src = path+"images/nav-inthenews-off.gif";

hdrmenu1_on = new Image();
hdrmenu1_on.src = path+"images/nav-subscribe-ner-on.gif";
hdrmenu2_on = new Image();
hdrmenu2_on.src = path+"images/nav-about-adp-report-on.gif";
hdrmenu3_on = new Image();
hdrmenu3_on.src = path+"images/nav-analysis-february-on.gif";
hdrmenu4_on = new Image();
hdrmenu4_on.src = path+"images/nav-resources-on.gif";
hdrmenu5_on = new Image();
hdrmenu5_on.src = path+"images/nav-media-on.gif";
hdrmenu6_on = new Image();
hdrmenu6_on.src = path+"images/nav-inthenews-on.gif";*/
ypSlideOutMenu.writeCSS();
	
	// this function repositions a menu to the speicified offset from center
function repositionMenu(menu, offset) {
	// the new left position should be the center of the window + the offset
	var newLeft = getWindowWidth() / 2 + offset;
	// setting the left position in netscape is a little different than IE
	menu.container.style ? menu.container.style.left = newLeft + "px" : menu.container.left = newLeft;
}
	
	// this function calculates the window's width - different for IE and netscape
function getWindowWidth() {
	return window.innerWidth ? window.innerWidth : document.body.offsetWidth;
}
