<!-- Begin

// Скрипт отображения илллюстраций материала 
// http://hotlinks.ru
// Автор А.Левченя, 2004 (аналог http://hotlinks.ru/hadpress/moscow/moscow.js)
// При подготовке скрипта использованы разработки С.А.Круглова
// http://www.kruglov.ru/articles/crossbrowserdhtml/
// http://www.kruglov.ru/klayers/

var loop=0,y,x,h_len,w_len;

var speed; // время задержки;
var velo,cur_velo; // позиция запуска и скорость скачков
var shown='';
var ns4up = (document.layers) ? 1 : 0; 
var ie4up = (document.all) ? 1 : 0;
var dx, xp, yp, cur_mousex, cur_mousey;
var am, stx, sty, size_w, size_h, w_flag,flag;
var i, doc_width = 800, doc_height = 600;

speed=1;
velo=2;

dx = 0;
xp = 0;
am = 0;
stx = 1;
sty = 0;

if (ie4up)
{ document.write("<div id=\"clip\" style=\"POSITION: absolute; Z-INDEX: "+ i +"; VISIBILITY: visible; TOP: 15px; LEFT: -1000px;\"></div>"); }

function lay_move(num,top,left) {
   document.all['clip'].style.pixelTop =  top; 
   document.all['clip'].style.pixelLeft = left;
}

function snow() {
  loop+=cur_velo;
  if (cur_velo>0)
  { if (loop>100) return; }
  else
  { if (loop<0) 
    { lay_move(shown,0,-1000); 
      shown='';
      return; 
    }
  }
  percent=loop/100;
  document.all['clip'].style.clip="rect("+size_h*(1-percent)+"px "+size_w+"px "+size_h+"px "+size_w*(1-percent)+"px)"
  setTimeout("snow()", speed);
}

function set_shown(arg,w,h)
{ 
  if (!ie4up)
  { window.open('2004/'+arg+'.html','','width='+w+',height='+h+',toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizeable=no'); 
    return;
  }
  if (shown=='')
  { factor=1; 
    shown=arg;
    document.all['clip'].innerHTML="<iframe src='2004/"+arg+".html' frameborder=0 vspace=0 hspace=0 width="+w+" height="+h+" marginwidth=0 marginheight=0 scrolling=no></a>";
    size_w=document.all['clip'].offsetWidth; 
    size_h=document.all['clip'].offsetHeight;
    loop=0;
    doc_width = document.body.clientWidth;
    doc_height = document.body.clientHeight;
    xp=document.body.scrollTop; 
    y=((doc_height-size_h)+xp);
    x=(doc_width-size_w);      
    lay_move(shown,y,x); 
  }
  else
  { if (factor==-1) { return; }
    factor=-1; 
  }
  cur_velo=velo*factor;
  snow();
}

// End -->


