// JavaScript Document

function SelectHouse(name, io){
  thisLayer = document.getElementById(name);
  thisFont = thisLayer.getElementsByTagName('font')[0];
  thisImg = thisLayer.getElementsByTagName('img')[0];
  if (io == 0){ // out
    thisFont.style.backgroundColor = "#eff5ea";
    thisFont.style.color = "#73ae3e";
    thisImg.style.opacity = ".5";
    thisImg.style.filter = "alpha(opacity=50)";
  }
  if (io == 1){ // in
    thisFont.style.backgroundColor = "#73ae3e";
    thisFont.style.color = "#FFFFFF";
    thisImg.style.opacity = "1";
    thisImg.style.filter = "alpha(opacity=100)";
  }
}
function SelectIndexHouse(name, io){
  thisLayer = document.getElementById(name);
  thisFont = thisLayer.getElementsByTagName('font')[0];
  thisImg = thisLayer.getElementsByTagName('img')[0];
  if (io == 0){ // out
    thisFont.style.backgroundColor = "";
    thisFont.style.color = "";
    thisImg.style.opacity = ".7";
    thisImg.style.filter = "alpha(opacity=70)";
  }
  if (io == 1){ // in
    thisFont.style.backgroundColor = "#46833e";
    thisFont.style.color = "#FFFFFF";
    thisImg.style.opacity = "1";
    thisImg.style.filter = "alpha(opacity=100)";
  }
}
 function SelectPix(name, io){
  thisLayer = document.getElementById(name);
  thisImg = thisLayer.getElementsByTagName('img')[0];
  if (io == 0){ // out
    thisImg.style.opacity = ".5";
    thisImg.style.filter = "alpha(opacity=50)";
  }
  if (io == 1){ // in
    thisImg.style.opacity = "1";
    thisImg.style.filter = "alpha(opacity=100)";
  }
}
function setStyle() {
 content = document.getElementById('LayerMainContent').offsetHeight+"px";
 document.getElementById('LayerLeft').style.height = content;
 document.getElementById('LayerRight').style.height = content;
}

function showImage(image) {
  document.getElementById('ShowImage').src = image;
}






function showInfo(type,set){
  if (ErrorMsgLayer = document.getElementById("LayerGalleryMailMsg")){
    ErrorMsgLayer.style.visibility = "hidden";
  }

  myLayer = document.getElementById("LayerGallery"+type);
  
  /* Ausblenden */
  document.getElementById("LayerGalleryMail").style.visibility = "hidden";
  document.getElementById("LayerGalleryInfo").style.visibility = "hidden";
  // arrDeaktivated = document.getElementsByName("InPicInfo");
  // for (x=0;x<=arrDeaktivated.length-1;x++){
  //   arrDeaktivated[x].style.visibility = "hidden";
  // }
  
  /* Bild größe Anpassen */
  ycontent = document.getElementById('ShowImage').offsetHeight+"px";
  xcontent = document.getElementById('ShowImage').offsetWidth+"px";
  
  myLayer.style.height = ycontent;
  myLayer.style.width = xcontent;
  myLayer.style.height = ycontent;
  myLayer.style.width = xcontent;

  /* Anzeigen */
  if (set){ myLayer.style.visibility = "visible"; }
}
function disableMsgBox(obj){
	// myBox = document.getElementById('MsgBox');
	obj.style.visibility = "hidden";
}




