<!--
function treeMenu(Id){
 menu = document.getElementById(Id).style;
 if(menu.display == "none"){
  menu.display="block";
 }else{
  menu.display="none"
	}
}



function startFix(layer_name,xx,yy){

    /* startFix()関数はfixedLAYER()関数と必ずセットで
       使ってください。
       このstartFix()関数内へ固定したいレイヤー名などを
       引数へ書いたfixedLAYER()関数をならべてください。 
    */

    fixedLAYER( layer_name ,'center',xx,yy)

  }
  //e4,e5,e6,n4,n6,n7,m1,o6,o7,s1用
  function fixedLAYER(layName,posString,offSetX,offSetY){
//レイヤーがonのとき

onoff1 = document.getElementById('Layer1').style.visibility;
onoff2 = document.getElementById('Layer2').style.visibility;
onoff3 = document.getElementById('Layer3').style.visibility;
onoff4 = document.getElementById('Layer4').style.visibility;


//		alert(onoff);

if (onoff1=='visible'||onoff2=='visible'||onoff3=='visible'||onoff4=='visible') {

//初期化
    if(!window.fixedLAYER[layName]){
      //--ブラウザ判定
      this.ie    = !!document.all
      this.n4    = !!document.layers
      this.w3c   = !!document.getElementById
      this.ua    = navigator.userAgent
      this.mac45 = ua.indexOf('MSIE 4.5; Mac_PowerPC') != -1
      this.mac5  = ua.indexOf('MSIE5.0;Mac_PowerPC')   != -1
      this.macie = ua.indexOf('Mac_PowerPC')  !=-1 && ie
      this.moz   = ua.indexOf('Gecko') !=-1
      this.opr   = !!window.opera
      //mace4.5以外のieはonscroll,onresizeするたびに動作
      if(this.ie&&!(this.mac45)){ 
          // fixedLAYER起動関数
          window.onscroll = window.onresize = startFix 
      }
      //--n4リサイズバグ回避用リロード処理
      if(this.n4)
        window.onresize = function(){ location.reload() }
      window.fixedLAYER[layName] = true
    }

    offSetX = parseInt(offSetX,10)
    offSetY = parseInt(offSetY,10)

    //--引数ごとの処理分岐
    if( posString == 'rightTop' ){
     
      if(this.ie&&!this.opr) 
            offLeft = document.body.clientWidth   + offSetX
      else  offLeft = window.innerWidth           + offSetX
      if(this.ie&&!this.opr) 
            offTop  =                               offSetY
      else  offTop  =                               offSetY

    } else if( posString == 'rightBottom' ){

      if(this.ie&&!this.opr) 
            offLeft = document.body.clientWidth   + offSetX
      else  offLeft = window.innerWidth           + offSetX
      if(this.ie&&!this.opr) 
            offTop  = document.body.clientHeight  + offSetY
      else  offTop  = window.innerHeight          + offSetY

    } else if( posString == 'leftBottom' ){

      if(this.ie&&!this.opr) 
            offLeft =                               offSetX
      else  offLeft =                               offSetX
      if(this.ie&&!this.opr) 
            offTop  = document.body.clientHeight  + offSetY
      else  offTop  = window.innerHeight          + offSetY

    } else if( posString == 'center' ){

      if(this.ie&&!this.opr) 
            offLeft = document.body.clientWidth/2 + offSetX
      else  offLeft = window.innerWidth/2         + offSetX
      if(this.ie&&!this.opr) {
//           offTop  = document.body.clientHeight/2+ offSetY;
			offTop  =  83; }
      else  {
//	  offTop  = window.innerHeight/2        + offSetY
	  offTop  =  83;}

    } else {

      if(this.ie&&!this.opr) 
            offLeft =                               offSetX
      else  offLeft =                               offSetX
      if(this.ie&&!this.opr) 
            offTop  =                               offSetY
      else  offTop  =                               offSetY

    }

    //--整数化する
    offLeft = parseInt(offLeft,10)
    offTop  = parseInt(offTop,10)

    //--ページ上のレイヤー位置xyを決める
    if(document.all&&!this.opr){
      var mx = document.body.scrollLeft + offLeft
      var my = document.body.scrollTop  + offTop
    } else {
      var mx = self.pageXOffset + offLeft
      var my = self.pageYOffset + offTop
    }


    //--レイヤーを動かす(maveLAYER()と同じ処理)
    if(document.getElementById){ //e5,e6,n6,n7,m1,o6,o7,s1用
        document.getElementById(layName).style.left = mx
        document.getElementById(layName).style.top  = my
    } else if(document.all){     //e4用
        document.all(layName).style.pixelLeft = mx
        document.all(layName).style.pixelTop  = my
    } else if(document.layers)   //n4用
        document.layers[layName].moveTo(mx,my)

    //Mace4.5とWinOperaはsetTimeoutでfixedLAYER()を起動する
    if(!(this.ie&&!this.mac45) || this.opr){
      clearTimeout(fixedLAYER[layName])
      fixedLAYER[layName]=setTimeout("fixedLAYER('"+layName+"','"+posString
                                     +"','" +offSetX+"','"+offSetY+"')",100)
    }
}
  }


function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);

function open_menu(on_off,layer_no) {

if (layer_no==1) {lay_x=-375;lay_y=83;}
if (layer_no==2) {lay_x=-375;lay_y=83;}
if (layer_no==3) {lay_x=-375;lay_y=83;}
if (layer_no==4) {lay_x=-375;lay_y=83;}

	document.getElementById("Layer"+layer_no).style.visibility = on_off;
startFix("Layer"+layer_no,lay_x,lay_y)
}
//	window.onResize = startFix("Layer"+cc,-100,-200);
//-->
