function preload(bild) 
{ 
   var myimages=new Array();
   for (i=0;i<preloadimages.arguments.length;i++)
   {
      myimages[i]=new Image();
      myimages[i].src=preloadimages.arguments[i];
   }
}


//bildergalerie
function gross(pic,breite,hoehe)
{
   var fenster = window.open("bilder.html?" + pic , "Bild", "scrollbars=0,toolbar=0,location=0,directories=0,status=0,resizable=1,left=0,top=0,width=" + breite + ",height=" + hoehe);
}


//impressum.html oeffnen
function impressum()
{
   var fenster = window.open("impressum.html", "Impressum", "scrollbars=1,toolbar=0,location=0,directories=0,status=0,resizable=1,left=0,top=0,width=660,height=500");
}


//Funktionen fuer die "schwebende Navigation" :
function setVariables()
{
  y1=159;ob=1;max=20;

  if (navigator.appName == "Netscape")
  {
    v=".top=";
    h=".left=";
    dS="document.";
    sD="";
    y="window.pageYOffset";
    x="window.pageXOffset";
    iW="window.innerWidth";
    iH="window.innerHeight"
  }
  else
  {
    h=".pixelLeft=";
    v=".pixelTop=";
    dS="";
    sD=".style";
    y="document.body.scrollTop";
    x="document.body.scrollLeft";
    iW="document.body.clientWidth";
    iH="document.body.clientHeight"
  }
  object="object1";
  checkLocationA();
}

function checkLocation()
{
   innerX=5; // von links
   innerY=159; // von oben

   if (document.layers)
   {
      innerY-=10;
      innerX-=10;
   }
   yy=eval(y);
   xx=eval(x);
   ydiff=ystart-yy;
   xdiff=xstart-xx;
   if ((ydiff<(-0.01))||(ydiff>(0.01)))
   {
      movey=Math.round(ydiff/10);
      ystart-=movey;
   }
   
   //keine horizontale Bewegung
//   if ((xdiff<(-0.01))||(xdiff>(0.01)))
//   {
//     movex=Math.round(xdiff/10);
//     xstart-=movex;
//  }

   N=(document.layers)?1:0 // Browsercheck (Version)
   V=(N) ? 4:5
   if (V==4)
   {
      object="object1";
      eval(dS+object+sD+v+(ystart+innerY+10));
      eval(dS+object+sD+h+(xstart+innerX+10));
   }
   else
   {
      object=document.getElementById('object1');
      object.style.top=ystart+innerY;
      object.style.left=xstart+innerX;
   }
   setTimeout("checkLocation()",10);
}

function checkLocationA()
{
   ystart=eval(y)+5;
   xstart=eval(x)+5;
   spread=40;
}

function scrollOn()
{
   items=1
   if (ob<=items)
   {
      objectX="object"+ob;
      y1+=10;
   }
   N=(document.layers)?1:0;
   V=(N)?4:5;
   if (V==4)
   {
      eval(dS + objectX + sD + v + y1);
   }
   else
   {
      object=document.getElementById(objectX);
      object.style.top=y1;
   }
   if (y1<max) xx=setTimeout("scrollOn()",20);
      else 
      {
         y1=-50;
         max+=spread;
         ob+=1;
         xx=setTimeout("scrollOn()",20);
      }
   if (ob>1)
   {
      clearTimeout(xx);
      checkLocation();
   }
}