
  // letajici banner 120 x 600px - posunuje se aby byl stale ve viditelne oblasti stranky

	var useWidth = "185";  // this is the width of the image;
	var useHeight = "139";  // this is its height;
	var useFloat = "";
	var slideTimer = "";	
	var initTop = 0;	
	var nScrollTop = 0;		
	var prevVal = 0;
	var currVal = 0;
	var throttlePx = 0;	
	var resizeTick = 0;
	var IE = true;
	if (navigator.appName != "Microsoft Internet Explorer"){IE = false}	

	function flyingskyscraperRealign(){
		if (!IE) {
			 flyingskyscraperInit();
		}
		if (IE && resizeTick == 2) {		
			 self.location.reload();	
		}
		resizeTick++;
	}

	function flyingskyscraperThrottle(){	
		clearTimeout(slideTimer);
		throttlePx += Math.floor((nScrollTop - throttlePx) * .5);			
		useFloat.style.top = initTop + throttlePx + "px";	
		if (Math.abs(throttlePx - nScrollTop) > 1) {
			 setTimeout("flyingskyscraperThrottle()", 40);
		} else	{
			 useFloat.style.top = initTop + nScrollTop + "px";
			 slideTimer = setTimeout("flyingskyscraperStayHome()", 500);
		}
	}

	function flyingskyscraperStayHome(){		
		if (document.documentElement && document.documentElement.scrollTop) {
			 nScrollTop = document.documentElement.scrollTop;	
			 document.getElementById('nScroll').value = nScrollTop;		
		} else {
			 nScrollTop = document.body.scrollTop;	
			 document.getElementById('nScroll').value = nScrollTop;			
		}		
		prevVal = document.getElementById('nScroll').value;
		if (prevVal == currVal) {				 
      clearTimeout(slideTimer);
      if (Number(nScrollTop) + Number(initTop) != useFloat.offsetTop) {					 
       flyingskyscraperThrottle();					 
      }				
		}
		currVal = document.getElementById('nScroll').value;	
		prevVal = currVal;		
		slideTimer = setTimeout("flyingskyscraperStayHome()", 500);		
	}


	function flyingskyscraperInit(){
		useFloat = document.getElementById('isFloat');
		if(!document.body.scrollTop) {
			 useFloat.style.top = "5px";
			 useFloat.style.left = "5px";
		} else {
			 useFloat.style.top = "5px";
			 useFloat.style.left = "5px"; 
		}
		initTop = useFloat.offsetTop;		
		flyingskyscraperStayHome();		
	}

