/*
Top Navigational Bar II (By Mike Hall @ Brainjar.com)
Last updated: 00/05/08
Permission granted to Dynamicdrive.com to include script in archive
For this and 100's more DHTML scripts, visit http://dynamicdrive.com
*/

var myNavBar1 = new NavBar(0);
var dhtmlMenu;

//define menu items (first parameter of NavBarMenu specifies main category width, second specifies sub category width in pixels)
//add more menus simply by adding more "blocks" of same code below

dhtmlMenu = new NavBarMenu(100, 0);
dhtmlMenu.addItem(new NavBarMenuItem("Home", "http://www.biology.ucsd.edu/labs/loomis/loomisweb.html"));
myNavBar1.addMenu(dhtmlMenu);

dhtmlMenu = new NavBarMenu(100, 120);
dhtmlMenu.addItem(new NavBarMenuItem("Research", "http://www.biology.ucsd.edu/labs/loomis/home.html"));
dhtmlMenu.addItem(new NavBarMenuItem("REMI", "/labs/loomis/REMI/index.html"));
dhtmlMenu.addItem(new NavBarMenuItem("Micro Array", "/loomis-cgi/microarray/index.html"));
dhtmlMenu.addItem(new NavBarMenuItem("Network Simulation", ""));
myNavBar1.addMenu(dhtmlMenu);

dhtmlMenu = new NavBarMenu(110, 120);
dhtmlMenu.addItem(new NavBarMenuItem("Publications", "/labs/loomis/publications/index.html"));
myNavBar1.addMenu(dhtmlMenu);

dhtmlMenu = new NavBarMenu(100, 150);
dhtmlMenu.addItem(new NavBarMenuItem("Members", ""));
dhtmlMenu.addItem(new NavBarMenuItem("William F. Loomis", "javascript: window.open('http://www-biology.ucsd.edu/shadow/sa/newbrochure/loomis.html')"));
myNavBar1.addMenu(dhtmlMenu);

dhtmlMenu = new NavBarMenu(100, 150);
dhtmlMenu.addItem(new NavBarMenuItem("Links", "/labs/loomis/links.html"));
myNavBar1.addMenu(dhtmlMenu);

//set menu color
myNavBar1.setColors("#000000", "#ffffff", "#0B619D", "#0B619D", "#ffffff", "#ffffff", "#0B619D", "#0B619D", "#ffffff")

//uncomment below line to center the menu (valid values are "left", "center", and "right"
//myNavBar1.setAlign("center")

var fullWidth;

function init() {

  // Get width of window, need to account for scrollbar width in Netscape.

  fullWidth = getWindowWidth() 
    - (isMinNS4 && getWindowHeight() < getPageHeight() ? 16 : 0);

  myNavBar1.resize(fullWidth);
  myNavBar1.create();
  myNavBar1.setzIndex(2);
}
