
//INSTRUMENTS
function Instr(section,fun) {

  var top,left,height

  if (section == "slide"){
    top = 40;
    left = 155;
    height = 550;
    }
  else{
    top = 20;
    left = 155;
    height = 550;
    }

  document.getElementById("Instr").style.display = "block"
  document.getElementById("Instr").style.top = top +"px"
  document.getElementById("Instr").style.left = left +"px"

  // VARIABILE DI OUTPUT
  output = "";

  //TABELLA STRUMENTO
  output += '<div id="InstrClose"><a href="javascript:InstrClose()" title="Chiudi" class="AInstrClose">chiudi</a></div>'
  output += '<iframe src="'+ section +'.htm'+ fun +'" style="width:660px;height:'+ height +'px" frameborder="0">Instrument</iframe>'


  //VISUALIZZO IL RISULTATO NEL BROWSER
  document.getElementById("Instr").innerHTML=output;

  }


//INSTRUMENT CLOSURE
function InstrClose() {

  document.getElementById("Instr").style.display = "none"
  document.getElementById("Instr").style.top = "0px"
  document.getElementById("Instr").style.left = "0px"

  // VARIABILE DI OUTPUT
  output = "";

  //VISUALIZZO IL RISULTATO NEL BROWSER
  document.getElementById("Instr").innerHTML=output;

  }
  
  //INSTRUMENT EVENING
function block(fun,id,pos) {
     
     if (fun=="view") {
       document.getElementById(""+ id +""+ pos +"").style.display = "block";
       document.getElementById(""+ id +"C"+ pos +"").style.display = "block";
       }
     else if (fun=="unview") {
       document.getElementById(""+ id +""+ pos +"").style.display = "none";
       document.getElementById(""+ id +"C"+ pos +"").style.display = "none";
       }

  }
