var mainIsVertical = false;

function mm_changeMenuProperty(menuName, propertyNumber, newValue)
{
  var menuNum = getMenuByName(menuName);
  _m[menuNum][propertyNumber] = newValue;
//  BDMenu(menuNum);
}
function toggleMainOrientation()
{
  var menuNum = getMenuByName("mainmenu");

  mainIsVertical = !mainIsVertical;

  if (mainIsVertical) {
   
    mm_changeMenuProperty("mainmenu", 9, "vertical");
    }
	
  else {
    
    mm_changeMenuProperty("mainmenu", 9, "horizontal");
  }

  BDMenu(menuNum);
}


/////

_menuCloseDelay=0 //100           // The time delay for menus to remain visible on mouse out
_menuOpenDelay=0 //100            // The time delay before menus open on mouse over
_subOffsetTop=0              // Sub menu top offset
_subOffsetLeft=-2            // Sub menu left offset

/// Style Definitions ///

with(mainStyleH=new mm_style()){
onbgcolor="#fefeee";
oncolor="#4F8EB6";
offbgcolor="#579b63";
offcolor="#f7f9f7";
bordercolor="#325235";
borderstyle="solid";
borderwidth=1;
separatorcolor="#325235";
separatorsize=2;
padding=4;
fontsize=12;
fontstyle="normal";
fontfamily="Verdana, Tahoma, Arial";
subimage="cut_black_white.gif";
onsubimage="cut_grey.gif";
subimagepadding=5;
high3dcolor="#edf3ee";
low3dcolor="#325235";
swap3d=1;
headerbgcolor="#548959";
headercolor="#f2f2ff";
}

with(mainStyleV=new mm_style()){
onbgcolor="#fefeee";
oncolor="#4F8EB6";
offbgcolor="#83ba8c";
offcolor="#f7f9f7";
bordercolor="#325235";
borderstyle="solid";
borderwidth=1;
separatorcolor="#325235";
separatorsize=2;
padding=4;
fontsize=12;
fontstyle="normal";
fontfamily="Verdana, Tahoma, Arial";
subimage="cut_black_white.gif";
onsubimage="cut_grey.gif";
subimagepadding=5;
high3dcolor="#edf3ee";
low3dcolor="#325235";
swap3d=1;
headerbgcolor="#548959";
headercolor="#f2f2ff";
}

with(dropStyle=new mm_style()){
onbgcolor="#BCBDDB";
oncolor="#323197";
offbgcolor="#9495B3";
offcolor="#FFFFFF";
bordercolor="#323197";
borderstyle="solid";
borderwidth=1;
separatorcolor="#323197";
separatorsize=2;
padding=3;
fontsize=11;
fontstyle="normal";
fontfamily="Verdana, Tahoma, Arial";
subimage="cut_black_white.gif";
onsubimage="cut_grey.gif";
subimagepadding=5;
high3dcolor="#E0E1FF";
low3dcolor="#70718F";
swap3d=1;
}

dropStyle1=new copyOf(dropStyle);
dropStyle1.onbgcolor="#d9e6e6";
dropStyle1.oncolor="#4b969a";
dropStyle1.offbgcolor="#4b969a";
dropStyle1.offcolor="#d9e6e6";
dropStyle1.high3dcolor="#bcdfe0";
dropStyle1.low3dcolor="#366c70";

dropStyle2=new copyOf(dropStyle);
dropStyle2.onbgcolor="#f5c149";
dropStyle2.oncolor="#fefeee";
dropStyle2.offbgcolor="#fef9ed";
dropStyle2.offcolor="#de8769";
dropStyle2.bordercolor="#b4f2f5";
dropStyle2.high3dcolor="#fefeee";
dropStyle2.low3dcolor="#f2a911";


/// Menu Definitions ///

// Main

with(milonic=new menuname("mainmenu")){
style=mainStyleH;
top=64;
left=20;
orientation="horizontal";
alwaysvisible=1;
itemwidth=125;
aI("text=Horz/Vert;url=javascript:toggleMainOrientation();status=Toggle Main Menu Orientation;offbgcolor=#548959;onbgcolor=#548959;offcolor=#f2f2ff;oncolor=#f2f2ff;");
aI("text=Milonic;url=http://www.milonic.com/;target=new;");
aI("text=Demos;url=http://support.milonic.com/;");
aI("text=Search Sites;showmenu=search;onbgcolor=#d9e6e6;oncolor=#4b969a;");
aI("text=News&nbsp;Sites;showmenu=news;onbgcolor=#f5c149;oncolor=#fefeee;");
aI("text=Next;url=page1.htm;");
}



/// Test Menus ///

// News

with(milonic=new menuname("news")){
style=dropStyle2;
aI("text=Newspapers;showmenu=newspapers;");
aI("text=Networks;showmenu=networks;");
aI("text=Tech News;showmenu=technews;");
}

with(milonic=new menuname("newspapers")){
style=dropStyle2;
aI("text=Los Angeles Times;url=http://www.latimes.com/;");
aI("text=New York Times;url=http://www.nytimes.com/;");
aI("text=USA Today;url=http://www.usatoday.com/;");
aI("text=Wall Street Journal;url=http://www.wsj.com/;");
aI("text=Washington Post;url=http://www.washingtonpost.com/;");
}

with(milonic=new menuname("networks")){
style=dropStyle2;
aI("text=ABC News;url=http://abcnews.go.com/;");
aI("text=BBC News;url=http://news.bbc.co.uk/shared/hi/interstitial-news.stm;");
aI("text=CBS News;url=http://www.cbsnews.com/;");
aI("text=CNN;url=http://www.cnn.com/;");
aI("text=FOX News;url=http://www.foxnews.com/;");
aI("text=MSNBC;url=http://www.msnbc.com/;");
}

with(milonic=new menuname("technews")){
style=dropStyle2;
aI("text=CNET News;url=http://news.com.com/;");
aI("text=Slash Dot;url=http://www.slashdot.com/;");
aI("text=Tech Web;url=http://www.techweb.com/;");
aI("text=Wired;url=http://www.wired.com/;");
}

// Search

with(milonic=new menuname("search")){
style=dropStyle1;
aI("text=Google;url=http://www.google.com/;");
aI("text=Yahoo;url=http://www.yahoo.com/;");
aI("text=Others;showmenu=otherSearch;");
}

with(milonic=new menuname("otherSearch")){
style=dropStyle1;
aI("text=Altavista;url=http://www.altavista.com/;");
aI("text=Ask Jeeves;url=http://www.ask.com/;");
aI("text=Excite;url=http://www.excite.com/;");
aI("text=Go.com;url=http://infoseek.go.com/;");
aI("text=Lycos;url=http://www.lycos.com/;");
}


/// Actions ///

with(milonic=new menuname("actionsmain")){
style=mainStyleV;
top=100;
left=150;
alwaysvisible=1;
itemwidth=123;
aI("text=Actions;type=header;align=center;fontweight=bold;");
aI("text=Main vert/horiz;url=javascript:toggleMainOrientation();status=Toggle Main Menu Orientation;");

}

drawMenus();

