/* This script and many more are available free online at
The JavaScript Source :: http://javascript.internet.com
Created by: Jacqueline Porjes :: http://porjes.com/example_css.html */

function show(Me) {
   var section = Me.parentNode;
   var menu = section.parentNode;
   for(var i = 0; i < menu.childNodes.length; i++) {
      if (menu.childNodes[i].length == 0) continue;
      if (typeof menu.childNodes[i].style != 'object') continue;
      menu.childNodes[i].style.width = '2em';
      menu.childNodes[i].style.background = 'url(../images/comunes/mback.jpg) #FBFDD7 repeat-y';
      menu.childNodes[i].style.color = '#000000';
   }
   section.style.width = '36em';
   section.style.background = "url(../images/comunes/mback2.jpg) #FBFDD7 repeat-y";
   section.style.color = '#000000';
  return true;
}

function showfirst() {
   if (!document.getElementsByTagName)
      return;
   var a = document.body.getElementsByTagName("div");
   for (i = 0; i < a.length; i++) {
      if (a[i].id == "flyout") {
         if (typeof a[i].style != 'object')
            continue;
         var x = a[i].getElementsByTagName("h2");
         for (j = 0; j < x.length; j++) {
            if (x[j].className == "showfirst") {
               if (typeof x[j].style != 'object')
                  continue;
               show(x[j]);
               return;
            }
         }
      }
  }
}
window.onload=showfirst;


/* Deshabilita al usuario la posibilidad de seleccionar texto */
function disableselect(e){return false}
function reEnable(){return true}
document.onselectstart=new Function ("return false")
if (window.sidebar){document.onmousedown=disableselect
document.onclick=reEnable}

/* Deshabilita al usuario la posibilidad de copiar imágenes*/
var message="Texto e imágenes no disponibles para descarga";
function clickIE4(){if (event.button==2){alert(message);return false;}}function clickNS4(e){if (document.layers||document.getElementById&&!document.all){if (e.which==2||e.which==3){alert(message);return false;}}}if (document.layers){document.captureEvents(Event.MOUSEDOWN);document.onmousedown=clickNS4;}else if (document.all&&!document.getElementById){document.onmousedown=clickIE4;}document.oncontextmenu=new Function("alert(message);return false")

