
var esFireFox = (navigator.userAgent != null && navigator.userAgent.indexOf( "Firefox/" ) != -1);

// Abre un popup con un html y una foto dada
function abreFoto(html,foto) {
	if (esFireFox) {
		var propiedades = 'width=300,height=300,top=5,left=5,scrollbars=yes,resizable=yes';
	} else {
		var propiedades = 'width=10,height=10,top=5,left=5,scrollbars=no';	
	}
	
	v=window.open(html+'?foto='+foto,'popupFoto',propiedades);
   	v.focus();
}


// Funciones control ventana navegador
function wSize() {
    if(navigator.appName == "Netscape") {
      iAlto = window.innerHeight;
      iAncho = window.innerWidth;
      iScrollAncho = document.width;
      iScrollAlto = document.height;
    }

    if (navigator.appVersion.indexOf("MSIE") != -1){
      if (navigator.appVersion.indexOf("Mac") == -1){
        iAncho=document.body.clientWidth;
        iAlto=document.body.clientHeight;
        iScrollAncho = document.body.scrollWidth;
        iScrollAlto = document.body.scrollHeight;
      }
    }
    myWidth = iScrollAncho;
    myHeight = iScrollAlto;
  return [myWidth, myHeight];
}

function escalaVentana() {
	if (!esFireFox) {
		sizeTemp = wSize();
		ancho = sizeTemp[0]+10;
		alto = sizeTemp[1]+25;
		window.resizeTo(ancho,alto);
	}
}

