// *** Will the browser be able to display the DHTML sitemap? ***

bIsCompatible = false;
if (window.opera)
  {
    var sUserAgent = navigator.userAgent;
    var sMatch = sUserAgent.match(/Opera[\/ ]7/i);
    var sMatch2 = sUserAgent.match(/Opera[\/ ]8/i);
    if (sMatch || sMatch2) bIsCompatible = true;
  }
else if (document.all) bIsCompatible = true;
else if (document.getElementById) bIsCompatible = true;

// *** Assign CSS classes to top level entries ***

sHomeCss="clLevel0TopLeft"
sProductsCss="clLevel0Top"
sServicesCss="clLevel0Top"
sDownloadCss="clLevel0Top"
sToolshopCss="clLevel0Top"
sSupportCss="clLevel0Top"
sCompanyCss="clLevel0Top"
sCustomerCss="clLevel0Top"
sBlogCss="clLevel0Top"

switch(sHighlightFlag)
  {
    case "home":
      sHomeCss="clLevel0TopActiveLeft";
      break;
    case "homeTwolines":
      sHomeCss="clLevel0TopActiveLeft";
      break;
    case "products":
      sProductsCss="clLevel0TopActive";
      break;
    case "productsOneline":
      sProductsCss="clLevel0TopActive";
      break;
    case "services":
      sServicesCss="clLevel0TopActive";
      break;
    case "download":
      sDownloadCss="clLevel0TopActive";
      break;
    case "toolshop":
      sToolshopCss="clLevel0TopActive";
      break;
    case "support":
      sSupportCss="clLevel0TopActive";
      break;
    case "company":
      sCompanyCss="clLevel0TopActive";
      break;
    case "customer":
      sCustomerCss="clLevel0TopActive";
      break;
	case "blog":
      sBlogCss="clLevel0TopActive";
      break;
  }

// *** Menu layer widths and direction ***

iHomeWidth=115;
// iProductsWidth=143;
iProductsWidth=230;
iServicesWidth=140;
iDownloadWidth=128;
iToolshopWidth=133;
iSupportWidth=69;
iCompanyWidth=155;
iCustomerWidth=133;
iBlogWidth=50;

// iTwoLinesHeight=32;
iTopTwoLinesHeight=37;
iFinalLineHeight=23;

function fTopmenu()
  {
    /***
    This is the menu creation code - place it right after you body tag
    Feel free to add this to a stand-alone js file and link it to your page.
    **/

    //Menu object creation
    oCMenuTop=new makeCM("oCMenuTop") //Making the menu object. Argument: menuname

    oCMenuTop.frames = 0

    //Menu properties
    oCMenuTop.pxBetween=0
//    oCMenuTop.fromLeft=(getPicLeft('topicon')+25)
    oCMenuTop.fromLeft=getPicLeft('topicon')
    oCMenuTop.fromTop=getPicTop('topicon')
    oCMenuTop.rows=1
    oCMenuTop.menuPlacement="left"

    oCMenuTop.offlineRoot=""
    oCMenuTop.onlineRoot=""
    oCMenuTop.resizeCheck=0
    oCMenuTop.wait=0
    oCMenuTop.fillImg="/objectif/images/null.gif"
    oCMenuTop.zIndex=0

    //Background bar properties
    oCMenuTop.useBar=0
    oCMenuTop.barWidth=0
    oCMenuTop.barHeight="menu"
    oCMenuTop.barClass="clBar"
    oCMenuTop.barX=0
    oCMenuTop.barY=0
    oCMenuTop.barBorderX=0
    oCMenuTop.barBorderY=0
    oCMenuTop.barBorderClass=""

    //Level properties - ALL properties have to be spesified in level 0
    oCMenuTop.level[0]=new cm_makeLevel() //Add this for each new level
    oCMenuTop.level[0].width=119
    oCMenuTop.level[0].height=25
    oCMenuTop.level[0].regClass="clLevel0Top"
    oCMenuTop.level[0].overClass="clLevel0overTop"
    oCMenuTop.level[0].borderX=0
    oCMenuTop.level[0].borderY=0
    oCMenuTop.level[0].borderClass="clLevel0border"
    oCMenuTop.level[0].offsetX=0
    oCMenuTop.level[0].offsetY=0
    oCMenuTop.level[0].rows=0
 //   oCMenuTop.level[0].arrow="/instep/images/menu_arrow_top.gif"
    oCMenuTop.level[0].arrowWidth=9
    oCMenuTop.level[0].arrowHeight=25
    // oCMenuTop.level[0].arrow=0
    // oCMenuTop.level[0].arrowWidth=0
    // oCMenuTop.level[0].arrowHeight=0
    oCMenuTop.level[0].align="bottom"

    //EXAMPLE SUB LEVEL[1] PROPERTIES - You have to specify the properties you want different from LEVEL[0] - If you want all items to look the same just remove this
    oCMenuTop.level[1]=new cm_makeLevel() //Add this for each new level (adding one to the number)
    oCMenuTop.level[1].width=150
    // oCMenuTop.level[1].width=oCMenuTop.level[0].width-2
    // oCMenuTop.level[1].height=22
    oCMenuTop.level[1].height=18
    oCMenuTop.level[1].regClass="clLevel1"
    oCMenuTop.level[1].overClass="clLevel1overTop"
    oCMenuTop.level[1].borderX=0
    oCMenuTop.level[1].borderY=0
    oCMenuTop.level[1].align="right"
    // oCMenuTop.level[1].offsetX=-(oCMenuTop.level[0].width-2)/2+20
    oCMenuTop.level[1].offsetX=0
    oCMenuTop.level[1].offsetY=0
    oCMenuTop.level[1].borderClass="clLevel1border"
//    oCMenuTop.level[1].arrow="/objectif/images/menu_arrow.gif"
    oCMenuTop.level[1].arrowWidth=10
    oCMenuTop.level[1].arrowHeight=9
    oCMenuTop.level[1].slidepx=10
    oCMenuTop.level[1].slidetim=20

    //EXAMPLE SUB LEVEL[2] PROPERTIES - You have to spesify the properties you want different from LEVEL[1] OR LEVEL[0] - If you want all items to look the same just remove this
    oCMenuTop.level[2]=new cm_makeLevel() //Add this for each new level (adding one to the number)
    oCMenuTop.level[2].width=150
    oCMenuTop.level[2].height=18
    oCMenuTop.level[2].offsetX=0
    oCMenuTop.level[2].offsetY=0
    oCMenuTop.level[2].regClass="clLevel2"
    oCMenuTop.level[2].overClass="clLevel2over"
    oCMenuTop.level[2].borderClass="clLevel2border"


    /******************************************
    Menu item creation:
    myCoolMenu.makeMenu(name, parent_name, text, link, target, width, height, regImage, overImage, regClass, overClass , align, rows, nolink, onclick, onmouseover, onmouseout)
    *************************************/
    oCMenuTop.makeMenu('top0','','Home',sAbsPath + '/index.htm','',58,'','','',sHomeCss,'clLevel0overTopLeft')
      oCMenuTop.makeMenu('sub00','top0','microTOOL Home',sAbsPath + '/index.htm','',iHomeWidth,iFinalLineHeight,'','','clLevel1Left','clLevel1overTopLeft')
      if (bIsCompatible == true)
        {
        //oCMenuTop.makeMenu('sub01','top0','Site-Map',sAbsPath + '/map.d/de/sitemap_ie.htm','',iHomeWidth,'','','','clLevel1Left','clLevel1overTopLeft')
        }
      else
        {
        //oCMenuTop.makeMenu('sub01','top0','Site-Map',sAbsPath + '/map.d/de/index.htm','',iHomeWidth,'','','','clLevel1Left','clLevel1overTopLeft')
        }
      oCMenuTop.makeMenu('sub02','top0','Suche','/asp/search/query.asp','',iHomeWidth,iFinalLineHeight,'','','clLevel1Left','clLevel1overTopLeft')
   //   oCMenuTop.makeMenu('sub03','top0','English',sAbsPath + '/asp/switch/switch.asp?url=' + this.location.href,'',iHomeWidth,iFinalLineHeight,'','','clLevel1Left','clLevel1overTopLeft')

    oCMenuTop.makeMenu('top1','','Produkte',sAbsPath + '/products/de/index.asp','',70,'','','',sProductsCss)

      oCMenuTop.makeMenu('sub13','top1','in-Step<br \/>Das Projektmanagement-Tool',sAbsPath + '/instep/de/index.asp','',iProductsWidth,iTopTwoLinesHeight)	  
      oCMenuTop.makeMenu('sub14','top1','objectiF<br \/>Das Tool f&uuml\;r UML und MDD',sAbsPath + '/objectif/de/index.asp','',iProductsWidth,iTopTwoLinesHeight)
	  oCMenuTop.makeMenu('sub12','top1','objectiF Requirements Modeller<br \/>Das Tool f&uuml\;r Requirements Engineering',sAbsPath + '/Requirements-Modeller/de/index.asp','',iProductsWidth,iTopTwoLinesHeight)
      oCMenuTop.makeMenu('sub16','top1','case/4/0<br \/>Das strukturierte Tool',sAbsPath + '/case40/de/index.asp','',iProductsWidth,iTopTwoLinesHeight)
      


    oCMenuTop.makeMenu('top7','','Dienstleistungen',sAbsPath + '/beratung/de/index.asp','',113,'','','',sServicesCss)
      oCMenuTop.makeMenu('sub70','top7','Softwaretechnik',sAbsPath + '/beratung/de/softwaretechnik.asp','',iServicesWidth, iFinalLineHeight)
      oCMenuTop.makeMenu('sub71','top7','IT-Projektmanagement',sAbsPath + '/beratung/de/projektmanagement.asp','',iServicesWidth, iFinalLineHeight)
      oCMenuTop.makeMenu('sub72','top7','Seminare',sAbsPath + '/products/de/seminare.asp','',iServicesWidth,iFinalLineHeight)

    oCMenuTop.makeMenu('top2','','Download',sAbsPath + '/download/de/index.asp','','73','','','',sDownloadCss)
//      oCMenuTop.makeMenu('sub21','top2','&Uuml;bersicht',sAbsPath + '/download/de/index.asp','',iDownloadWidth)
      oCMenuTop.makeMenu('sub22','top2','in-Step',sAbsPath + '/instep/de/download.asp','',iDownloadWidth, iFinalLineHeight)
      oCMenuTop.makeMenu('sub23','top2','objectiF',sAbsPath + '/objectif/de/download.asp','',iDownloadWidth, iFinalLineHeight)
  //    oCMenuTop.makeMenu('sub24','top2','microTOOL Suite .NET',sAbsPath + '/suite/de/test.asp','',iDownloadWidth)
      oCMenuTop.makeMenu('sub25','top2','case/4/0',sAbsPath + '/case40/de/download.asp','',iDownloadWidth,iFinalLineHeight)

//    oCMenuTop.makeMenu('top3','','ToolShop',sAbsPath + '/toolshop/index.asp','',71,'','','',sToolshopCss)
//        oCMenuTop.makeMenu('sub30','top3','microTOOL Suite .NET','https://www.microtool.de/ts_ssl/49/su_index.asp','',iToolshopWidth)
//        oCMenuTop.makeMenu('sub31','top3','in-Step','https://www.microtool.de/ts_ssl/49/is_index.asp','',iToolshopWidth)
//        oCMenuTop.makeMenu('sub32','top3','objectiF','https://www.microtool.de/ts_ssl/49/ob_index.asp','',iToolshopWidth)
//      oCMenuTop.makeMenu('sub33','top3','case/4/0','https://www.microtool.de/ts_ssl/49/ca_index.asp','',iToolshopWidth,iFinalLineHeight)

    oCMenuTop.makeMenu('top4','','Support',sAbsPath + '/support/de/index.asp','',63,'','','',sSupportCss)
      oCMenuTop.makeMenu('sub40','top4','in-Step',sAbsPath + '/support/de/is_index.asp','',iSupportWidth, iFinalLineHeight)
      oCMenuTop.makeMenu('sub41','top4','objectiF',sAbsPath + '/support/de/ob_index.asp','',iSupportWidth, iFinalLineHeight)
      oCMenuTop.makeMenu('sub42','top4','case/4/0',sAbsPath + '/support/de/ca_index.asp','',iSupportWidth,iFinalLineHeight)

    oCMenuTop.makeMenu('top5','','Unternehmen',sAbsPath + '/company/de/index.asp','',95,'','','',sCompanyCss)
      oCMenuTop.makeMenu('sub50','top5','&Uuml;ber microTOOL',sAbsPath + '/company/de/aboutus.asp','',iCompanyWidth, iFinalLineHeight)
      oCMenuTop.makeMenu('sub51','top5','Unternehmensgeschichte',sAbsPath + '/company/de/history.asp','',iCompanyWidth, iFinalLineHeight)
      oCMenuTop.makeMenu('sub52','top5','Gesch&auml\;ftsf&uuml\;hrung',sAbsPath + '/company/de/geschfuehr.asp','',iCompanyWidth, iFinalLineHeight)
      oCMenuTop.makeMenu('sub53','top5','Standort',sAbsPath + '/company/de/anschrift.asp','',iCompanyWidth, iFinalLineHeight)
     // oCMenuTop.makeMenu('sub54','top5','News-Archiv',sAbsPath + '/company/de/news.asp','',iCompanyWidth)
        oCMenuTop.makeMenu('sub55','top5','Newsletter-Service',sAbsPath + '/company/de/newsletter.asp','',iCompanyWidth, iFinalLineHeight)
      oCMenuTop.makeMenu('sub56','top5','Konferenzen &amp; Events',sAbsPath + '/company/de/kongress.asp','',iCompanyWidth, iFinalLineHeight)
        oCMenuTop.makeMenu('sub57','top5','Ver&ouml;ffentlichungen',sAbsPath + '/asp/company/veroeff.asp','',iCompanyWidth, iFinalLineHeight)
        oCMenuTop.makeMenu('sub58','top5','Presse',sAbsPath + '/presse/de/index.asp','',iCompanyWidth, iFinalLineHeight)
        oCMenuTop.makeMenu('sub59','top5','Jobs',sAbsPath + '/jobs/de/index.asp','',iCompanyWidth, iFinalLineHeight)
        oCMenuTop.makeMenu('sub590','top5','Ansprechpartner',sAbsPath + '/company/de/kontakt.asp','',iCompanyWidth, iFinalLineHeight)
        oCMenuTop.makeMenu('sub591','top5','Impressum',sAbsPath + '/company/de/impressum.asp','',iCompanyWidth, iFinalLineHeight)
        oCMenuTop.makeMenu('sub592','top5','Datenschutzerkl&auml\;rung',sAbsPath + '/company/de/privacy.asp','',iCompanyWidth,iFinalLineHeight)

    oCMenuTop.makeMenu('top6','','Referenzen',sAbsPath + '/forum/de/index.asp','',75,'','','',sCustomerCss)
//      oCMenuTop.makeMenu('sub60','top6','&Uuml;bersicht',sAbsPath + '/forum/de/index.htm','',iCustomerWidth)
      oCMenuTop.makeMenu('sub61','top6','Kunden',sAbsPath + '/customer/de/index.asp','',iCustomerWidth, iFinalLineHeight)
  //    oCMenuTop.makeMenu('sub62','top6','Partner',sAbsPath + '/partner/de/index.asp','',iCustomerWidth, iFinalLineHeight)
      oCMenuTop.makeMenu('sub64','top6','Aus Kundenprojekten',sAbsPath + '/forum/de/anwenderberichte.asp','',iCustomerWidth,iFinalLineHeight)
	  
	  oCMenuTop.makeMenu('top8','','Blog','http://microtool.de/blog/','_blank',iBlogWidth,'','','',sBlogCss)

      //Leave this line - it constructs the menu
    oCMenuTop.construct()
  }

fReady('topmenu');
