// global positioning var
var xpos;
var xwidth;

function MenuBuild() {    

    is = new BrowserCheck();
    TI = new TreeItem(0,0,"items2","","");
    if (!W) W=900;

    wAdj=0;
	ns=document.layers;
	ie=document.all;
	op=window.opera;
	chrome=navigator.userAgent.indexOf("Chrome")>0;
    if (ns) wAdj+=-8;
    if (ie && navigator.userAgent.indexOf("Win")>0) wAdj+=-9;
    if (ie && navigator.userAgent.indexOf("Mac")>0) wAdj+=2;
    if (op) wAdj+=10;
    
    TI.xpos=W/2-179+wAdj;
    xwidth = 90;
    if (ie) TI.xpos=W/2-279+wAdj;
    if (ie) xwidth = 70;
    if (chrome) TI.xpos=W/2-279+wAdj;
    if (chrome) xwidth = 70; //spacing between main entries


    xpos = TI.xpos;
    //TI.xpos=W/2;
    TI.ypos=72;//41
    TI.align="hor";
    
    // Global background/selected color
    TI.bckColor="#000000";
    TI.selBckColor="#000000";
    
    // Global background/selected color for NS4
    TI.bckColorNS4="#000000";
    TI.selBckColorNS4="#000000";
    
    // Global font/selected color
    TI.fntColor="#EBEBEB";
    TI.selFntColor="#EB4646";
    
    // Global font properties
    TI.face="arial,helvetica,sans-serif";
    TI.width=165;
    TI.fntSize=11;
    TI.fntSizeNS4=1; // HTML size, not pixels
    TI.i=false;
    TI.b=true;
    TI.iHeight=20;
    TI.imWidth=20;

    // Border size/color
    TI.bSize=1;
    TI.bColor="#EBEBEB";
    //TI.bckImage="h73cover_thumb.jpg";
    //TI.arrIm="list-img1.gif";
    
    // Example:
    // ================================================
    // TI.A(id,parid,name,link,target,image,im2,iw,ih);
    
    TI.A(100,0,"Home","index.html","top","","",xwidth,25);
    TI.A(101,0,"Products","","","","",xwidth);
	TI.A(1011,101,"Telecom","telecom/index.html","top","");
		TI.A(10111,1011,"PowerQor","powerqor/index.html","top","");
		TI.A(10112,1011,"BusQor","busqor/index.html","top","");
		TI.A(10113,1011,"NiQor","niqor/index.html","top","");
		TI.A(10114,1011,"ATCA","ATCA/index.html","top","");
		TI.A(10115,1011,"EMI Filters","filters/index.html","top","");
	TI.A(1012,101,"Industrial","industrial/index.html","top","");
		TI.A(10121,1012,"InQor","inqor/index.html","top","");
		TI.A(10122,1012,"RailQor","railqor/index.html","top","");
		TI.A(10123,1012,"NiQor","niqor/index.html","top","");
		TI.A(10124,1012,"NiQor (Hi-Voltage)","niqor/niqor-hivolt.html","top","");
		TI.A(10125,1012,"ACuQor (AC/DC)","acuqor/acuqor-ind.html","top","");
		TI.A(10126,1012,"EMI Filters","filters/index.html","top","");
	TI.A(1013,101,"Medical","medical/index.html","top","");
		TI.A(10131,1013,"ACuQor (AC/DC)","acuqor/acuqor-med.html","top","");
		TI.A(10132,1013,"CF Defibrillation Proof","cfqor/index.html","top","");	
		TI.A(10133,1013,"InQor","inqor/index.html","top","");
		TI.A(10134,1013,"NiQor","niqor/index.html","top","");
		TI.A(10135,1013,"NiQor (Hi-Voltage)","niqor/niqor-hivolt.html","top","");
		TI.A(10136,1013,"EMI Filters","filters/index.html","top","");
	TI.A(1014,101,"Military","military/index.html","top","");
		TI.A(10141,1014,"MilQor Hi-Rel","milqor-hirel/index.html","top","");
		TI.A(10142,1014,"MilQor Mil-COTS","milqor-milcots/index.html","top","");
		TI.A(10143,1014,"EMI Filters","filters/index.html","top","");
//	TI.A(1015,101,"Military Power Solns","mps/index.html","top","");
//		TI.A(10151,1015,"MilQor DC/DC VME Card","dcdcvme/index.html","top","");
//		TI.A(10152,1015,"MilQor AC/DC VME Card","acdcvme/index.html","top","");
	TI.A(1016,101,"UPS","ups/index.html","top","");
		TI.A(10161,1016,"Military UPS","ups/index.html","top","");
	TI.A(1017,101,"Accessories","support-technical-documents-Acc.html","top","");
	TI.A(1018,101,"Application Notes","support-technical-documents-AN.html","top","");
	TI.A(1019,101,"Product Selector","DSLMain.aspx","top","");
        TI.A(10110,101,"Product Summary Tables","prodsmrytbls.aspx","top","");
    TI.A(102,0,"Company","","","","",xwidth);
	TI.A(1021,102,"About Us","company-about-us.html","top","");
	TI.A(1022,102,"Career Opportunities","company-careers.html","top","");
	TI.A(1023,102,"Organization","company-organization.html","top","");
	TI.A(1024,102,"Press Releases","company-press.html","top","");
	TI.A(1025,102,"Media Center","company-media-center.html","top","");
    TI.A(103,0,"Sales","","","","",xwidth);
	TI.A(1031,103,"Sales Locations","sales-contact.html","top","");
	TI.A(1032,103,"Sales FAQ","sales-faq.html","top","");
		// TI.A(1033,103,"Distributors","disti-list.html","top","");
    TI.A(104,0,"Quality","","","","",xwidth);
	TI.A(1041,104,"Safety","products-safety-certifications.html","top","");
	TI.A(1042,104,"RoHS Compliance","products-lead-free.html","top","");
	TI.A(1043,104,"ISO-9001","company-ISO9001.html","top","");
	TI.A(1044,104,"Manufacturing","company-manufacturing.html","top","");
	TI.A(1045,104,"DOSA","products-dosa.html","top","");
    TI.A(105,0,"Contact","","","","",xwidth);
	TI.A(1051,105,"General Inquiry/Feedback","email_general.html","top","");
	TI.A(1052,105,"Technical Support","email_techreq.html","top","");
	TI.A(1053,105,"Request Product Info","email_signup.html","top","");
//    	TI.A(1054,105,"Technical Library","","","");
	TI.A(1055,105,"Application Notes","support-technical-documents-AN.html","top","");
	TI.A(1056,105,"White Papers","support-technical-documents-WP.html","top","");
	TI.A(1057,105,"Design Tools","support-technical-documents-Misc.html","top","");
	TI.A(1058,105,"Change Notices","support-technical-documents-Misc.html","top","");
	TI.A(1059,105,"Evaluation Board Info","support-technical-documents-Misc.html","top","");
	TI.A(10510,105,"Accessories","support-technical-documents-Acc.html","top","");
	TI.A(10511,105,"Contact us","contact.html","top","","","");
	TI.A(10512,105,"FAQs","support-FAQ.html","top","");
            //TI.A(1057,105,"Request for Quote","","top","");

    // Individual Styling
    TI.d=1;
    
    // HOME - ID#: 100
    TI.Get(100).bckColor="transparent";
    TI.Get(100).selBckColor="transparent";
    TI.Get(100).bckColorNS4="#ffffff";
    TI.Get(100).selBckColorNS4="#ffffff";
    TI.Get(100).selFntColor="#EB4646";
    TI.Get(100).textAlign="center";
    TI.Get(100).fntSize=12;
    
    // PRODUCTS - ID#: 101
    TI.Get(101).bckColor="transparent";
    TI.Get(101).selBckColor="transparent";
    TI.Get(101).bckColorNS4="#ffffff";
    TI.Get(101).selBckColorNS4="#ffffff";
    TI.Get(101).selFntColor="#EB4646";
    TI.Get(101).textAlign="center";
    TI.Get(101).fntSize=12;
    
    // COMPANY - ID#: 102
    TI.Get(102).bckColor="transparent";
    TI.Get(102).selBckColor="transparent";
    TI.Get(102).bckColorNS4="#ffffff";
    TI.Get(102).selBckColorNS4="#ffffff";
    TI.Get(102).selFntColor="#EB4646";
    TI.Get(102).textAlign="center";
    TI.Get(102).fntSize=12;
    
    // SALES - ID#: 103
    TI.Get(103).bckColor="transparent";
    TI.Get(103).selBckColor="transparent";
    TI.Get(103).bckColorNS4="#ffffff";
    TI.Get(103).selBckColorNS4="#ffffff";
    TI.Get(103).selFntColor="#EB4646";
    TI.Get(103).textAlign="center";
    TI.Get(103).fntSize=12;
    
    // SUPPORT - ID#: 104
    TI.Get(104).bckColor="transparent";
    TI.Get(104).selBckColor="transparent";
    TI.Get(104).bckColorNS4="#ffffff";
    TI.Get(104).selBckColorNS4="#ffffff";
    TI.Get(104).selFntColor="#EB4646";
    TI.Get(104).textAlign="center";
    TI.Get(104).fntSize=12;
    
    // CONTACT - ID#: 105
    TI.Get(105).bckColor="transparent";
    TI.Get(105).selBckColor="transparent";
    TI.Get(105).bckColorNS4="#ffffff";
    TI.Get(105).selBckColorNS4="#ffffff";
    TI.Get(105).selFntColor="#EB4646";
    TI.Get(105).textAlign="center";
    TI.Get(105).fntSize=12;
    
    
    TI.bSize=0;
    TI.width=80;
    TI.arrIm="";
    TI.WriteCSS();
    TI.WriteDiv();
}

function MenuInit() {
    window.onresize= function(){ window.history.go(0) };
    TI.EventInit();
}

function Reset() {
    TI.Reset();
}
