//////////////////////////////////////////////////////////////////
//																//
//	Weill Cornell Medical College								//
//	cornellsurgery.org site javascript							//
//	cornellsurgery.js											//
//	Version 1.5 												//											
//																//
//////////////////////////////////////////////////////////////////

// ::::::::::::::::::::::::::: SECTION I: preload top nav images: three state rollovers

// fill in the absolute paths for all the images
if (browser) {
	one_on = new Image; one_on.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_abo_us_on.gif";
	one_off = new Image; one_off.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_abo_us_off.gif";
	one_active = new Image; one_active.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_abo_us_on.gif";
	
	two_on = new Image; two_on.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_our_fac_on.gif";
	two_off = new Image; two_off.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_our_fac_off.gif";
	two_active = new Image; two_active.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_our_fac_on.gif";

	three_on = new Image; three_on.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_pro_stu_on.gif";
	three_off = new Image; three_off.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_pro_stu_off.gif";
	three_active = new Image; three_active.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_pro_stu_on.gif";

	four_on = new Image; four_on.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_res_pos_on.gif";
	four_off = new Image; four_off.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_res_pos_off.gif";
	four_active = new Image; four_active.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_res_pos_on.gif";
	
	five_on = new Image; five_on.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_new_eve_on.gif";
	five_off = new Image; five_off.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_new_eve_off.gif";
	five_active = new Image; five_active.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_new_eve_on.gif";	

	seven_on = new Image; seven_on.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_med_col_hom_on.gif";
	seven_off = new Image; seven_off.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_med_col_hom_off.gif";
	seven_active = new Image; seven_active.src="http://images.med.cornell.edu/headers/navbar/cornellmicrobiology/hea_med_col_hom_on.gif";	

}

// ::::::::::::::::::::::::::: SECTION II: set values for panos, use absolute paths for all file locations

// flash pano: use this if using only one pano for the whole site
//panoLoc				= "http://media.med.cornell.edu/panoramas/nyp/pano_home.swf";

// flash pano: use this if using different pano for each section
if (active == "" && activeHome == "home") {
	panoLoc = "http://media.med.cornell.edu/panoramas/cornellmicrobiology/pano_home.swf";
} else if (active == "one") {
	panoLoc = "http://media.med.cornell.edu/panoramas/cornellmicrobiology/pano_" + active + ".swf";
} else if (active == "two") {
	panoLoc = "http://media.med.cornell.edu/panoramas/cornellmicrobiology/pano_" + active + ".swf";
} else if (active == "three") {
	panoLoc = "http://media.med.cornell.edu/panoramas/cornellmicrobiology/pano_" + active + ".swf";
} else if (active == "four") {
	panoLoc = "http://media.med.cornell.edu/panoramas/cornellmicrobiology/pano_" + active + ".swf";
} else if (active == "five") {
	panoLoc = "http://media.med.cornell.edu/panoramas/cornellmicrobiology/pano_" + active + ".swf";	
} else if (active == "six") {
	panoLoc = "http://media.med.cornell.edu/panoramas/cornellmicrobiology/pano_" + active + ".swf";	
} else { //default to this just in case
	panoLoc = "http://media.med.cornell.edu/panoramas/cornellmicrobiology/pano.swf";
}
		
// set animation to true or false		
inAnimation			= "false";

// static pano: use this if using different pano for each section
if (active == "" && activeHome == "home") {
	altPanoLoc = "http://images.med.cornell.edu/panoramas/cornellmicrobiology/home.jpg";
} else if (active == "one") {
	altPanoLoc = "http://images.med.cornell.edu/panoramas/cornellmicrobiology/pano_" + active + ".jpg";
} else if (active == "two") {
	altPanoLoc = "http://images.med.cornell.edu/panoramas/cornellmicrobiology/pano_" + active + ".jpg";
} else if (active == "three") {
	altPanoLoc = "http://images.med.cornell.edu/panoramas/cornellmicrobiology/pano_" + active + ".jpg";
} else  if (active == "four") {
	altPanoLoc = "http://images.med.cornell.edu/panoramas/cornellmicrobiology/pano_" + active + ".jpg";
} else  if (active == "five") {
	altPanoLoc = "http://images.med.cornell.edu/panoramas/cornellmicrobiology/pano_" + active + ".jpg";
} else { //default to this just in case
	altPanoLoc = "http://images.med.cornell.edu/panoramas/cornellmicrobiology/pano.jpg";
}		
	
// lefthand nav homepage link
siteURL = "http://www.cornellmicrobiology.com/";

// set xml data for pano flash here
dataLoc				= "http://global.med.cornell.edu/panoramas/cornellmicrobiology/data.xml";

// set this line to the location of the temp toolbar when working on the test server. comment it out to move to production
toolBarLoc			= "http://media.med.cornell.edu/panoramas/framework_toolbar" + homeWrapper + ".swf";

// set loading value here: wmc or nyp
brand				= "wmc";

// setting the array, don't touch
buttonArray			= new Array ();

// set absolute paths for all the pano toolbar links [image map for static pano]
buttonArray[0]		= new createButtonObject (4, "http://www.weill.cornell.edu/search/search_advanced.html");
buttonArray[1]		= new createButtonObject (5, "http://www.cornellmicrobiology.com/contact.html");
buttonArray[2]		= new createButtonObject (7, "http://www.weill.cornell.edu/contact/maps.html");

// setting the array, don't touch
additionalMapArray	= new Array ();


// ::::::::::::::::::::::::::: SECTION III: set 2nd and 3rd level navigation links here, customize according to section

// needed for 4th level links grey line, don't touch
var num4thLevelLinks = 0;

// load 2nd and 3rd level navigation here
function loadLinks() {
	
	// setting the array, don't touch this line
	var navLinks = new Array();
		
	if (active == "one") {
	    
		navLinks[0] = new LeftLink('Welcome from the Chair', 'http://www.cornellmicrobiology.com/abo_us/index.html', '2', '', '');
		navLinks[1] = new LeftLink('Mission', 'http://www.cornellmicrobiology.com/abo_us/mission.html', '2', '', '');
		navLinks[2] = new LeftLink('Core Services', 'http://www.cornellmicrobiology.com/abo_us/cor_ser.html', '2', '', '');

	}  else if (active == "two") {
		
		navLinks[0] = new LeftLink('Primary Faculty', 'http://www.cornellmicrobiology.com/our_fac/index.html', '2', '', '');	
		navLinks[1] = new LeftLink('Faculty with Joint, Secondary or Adjunct Appointments', 'http://www.cornellmicrobiology.com/our_fac/secondary.html', '2', '', '');	

	} else if (active == "three") {
		
		// customize section three, 2nd and 3rd level navigation links here		
		
	} else if (active == "four") {
		
		// customize section three, 2nd and 3rd level navigation links here
		
	} else if (active == "five") {
	
		// customize section three, 2nd and 3rd level navigation links here	
		
	} else if (active == "six") {
		
		// customize section three, 2nd and 3rd level navigation links here	
		
		
	} else if (active == "") {
		
		if (activeTool == "contact") {
			navLinks[0] = new LeftLink('Contact Us', 'http://www.cornellmicrobiology.com/contact.html', '2', '', '');
		} else if (activeTool == "maps") {
			navLinks[0] = new LeftLink('Maps and Directions', 'http://www.cornellmicrobiology.com/maps.html', '2', '', '');			
		}
	}
	// returning the value here, don't touch
	return (navLinks);
}

