count = 0;
count2 = 80;
pontinho= '|';

function precarrega(){
imgVar = new Image();
imgVar.src = imagemVar;
loadCheck();
}

function loadCheck(){
if(pontinho.length == 20){
pontinho = '|';
}
pontinho = pontinho + '|';

if(imgVar.complete || navigator.appName == "Netscape"){
terminacount();

if(imgVar.width >= screen.availWidth || imgVar.height >= screen.availHeight){
scrollVar="yes";
}
else{ scrollVar="no";
}
vleft=Math.round((screen.availWidth-imgVar.width)/2);
vtop=Math.round((screen.availHeight-imgVar.Height)/2);

configura="width="+imgVar.width+",innerHeight="+imgVar.height+",resizable=no,scrollbars="+scrollVar+",left="+vleft+",top="+vtop;

pop=window.open('foto.html','',configura);

count=0;

if(navigator.appName == "Netscape"){
setTimeout("pop.location.reload();", 500);
//setTimeout("pop.location.reload();", 200);
}}
else{
if(count < 80){
count = count + 1;
setTimeout('loadCheck()',200);
window.status = 'Carregando Imagem!!! ==> '+count+'% '+pontinho;
}
else{
setTimeout('loadCheck()',200);
window.status = 'Carregando Imagem!!! ==> '+count2+'% '+pontinho;
}
}
}

function terminacount(){
if(count2 < 100){
count2 = count2 + 5;
window.status = 'Imagem Carreganda !!! ==> '+count2+'%';
setTimeout('terminacount()',10);
}
else {
window.status = 'Imagem Carregada !!! ==> 100%';
}
}