/*function fenster ()
	{
		var win1; 
		window.resizeTo(250,2000);
		window.moveTo (0,0);
		window.blur();
		window.focus();

	} */

var popUps;
var actX;
var actY;
var dimX;
var dimY;
actX = 250;
actY = 0;
dimX = 180;
dimY = 150;
popUps = Array()

	
		
function CheckOpen (popUps) {
  if (popUp.closed == true) {
    alert("Fenster wurde geschlossen");
  } else {
    alert("Fenster noch offen");
  }
}


function wop(name,x,y)
{
		
		
		
		isOpen = 0 
		// schlaufe ueber alle fenster
		for(i=0;i<popUps.length;i++)
		{
			//alert(i+" "+popUps[i].name)
			popUps[i].focus();
			
			
			if (popUps[i].name == name)
				isOpen = 1	
				
		}
		// ende schlaufe
		
		
		if (isOpen == 0)
		{
			// fenster neu oeffnen
			win=window.open (name+".html", name, "width="+dimX+",height="+dimY+" ,resizable=no, location=no,");
			win.moveTo (actX,actY)
			popUps[popUps.length] = win
			
			// ende fenster neu oeffnen
			
			// cursor verschieben
			if(actX+dimX+dimX < screen.availWidth)
				actX += dimX
			else{
				actX = 250 
				actY += dimY+15
			}	
			
			if(actY+dimY > screen.availHeight)
			{
				actX = 250
				actY = 0
			}	

				
		// ende cursor verschieben
		
		}
			
		
}

/*

function fenster1 ()
	{
		var win; 
		win=window.open ("alice.html", "alice", "width=180,height=150 ,resizable=no, location=no,");
		win.moveTo (250,0)
		
		}
		
function fenster2 ()
	{
		var win; 
		win=window.open ("andi.html", "andi", "width=180,height=150, screenX=240, screenY=300, resizable=no");
		win.moveTo (430,0)
		
	}
	
function fenster3 ()
	{
		var win; 
		win=window.open ("andrea.html", "andrea", "width=180,height=150, screenX=420,screenY=300,resizable=no");
		win.moveTo (610,0)
		
	}
	
function fenster4 ()
	{
		var win; 
		win=window.open ("andreas.html", "andreas", "width=180,height=150, screenX=600,screenY=300,resizable=no");
		win.moveTo (790,0)
		
	}
	
function fenster5 ()
	{
		var win; 
		win=window.open ("andri.html", "andri", "width=180,height=150, screenX=780,screenY=300,resizable=no");
		win.moveTo (250,185)
	}
	
function fenster6 ()
	{
		var win; 
		win=window.open ("benjamin.html", "benjamin", "width=180,height=150, screenX=60,screenY=490,resizable=no");
		win.moveTo (430,185)
	}
	
	function fenster7 ()
	{
		var win; 
		win=window.open ("caro.html", "caro", "width=180,height=150, screenX=240,screenY=490,resizable=no");
		win.moveTo (610,185)
	}
	
	function fenster8 ()
	{
		var win; 
		win=window.open ("celia.html", "celia", "width=180,height=150, screenX=420,screenY=490,resizable=no");
		win.moveTo (790,185)
	}
	
	function fenster9 ()
	{
		var win; 
		win=window.open ("christoph.html", "christoph", "width=180,height=150, screenX=600,screenY=490,resizable=no");
		win.moveTo (250,370)
	}
	
	function fenster10 ()
	{
		var win; 
		win=window.open ("denis.html", "denis", "width=180,height=150, screenX=780,screenY=490,resizable=no");
		win.moveTo (430,370)
	}
	
	function fenster11 ()
	{
		var win; 
		win=window.open ("dina.html", "dina", "width=180,height=150, screenX=60,screenY=300,resizable=no");
		win.moveTo (610,370)
		
	}
	
	function fenster12 ()
	{
		var win; 
		win=window.open ("eva.html", "eva", "width=180,height=150, screenX=240,screenY=300,resizable=no");
		win.moveTo (790,370)
	}
	
	function fenster13 ()
	{
		var win; 
		win=window.open ("evaa.html", "evaa", "width=180,height=150, screenX=420,screenY=300,resizable=no");
		win.moveTo (250,555)
	}
	
	function fenster14 ()
	{
		var win; 
		win=window.open ("felix.html", "felix", "width=180,height=150, screenX=600,screenY=300,resizable=no");
		win.moveTo (430,555)
	}
	
	function fenster15 ()
	{
		var win; 
		win=window.open ("flo.html", "flo", "width=180,height=150, screenX=780,screenY=300,resizable=no");
		win.moveTo (610,555)
	}
	
	function fenster16 ()
	{
		var win; 
		win=window.open ("fredi.html", "fredi", "width=180,height=150, screenX=60,screenY=490,resizable=no");
		win.moveTo (790,555)
	}
	
	function fenster17 ()
	{
		var win; 
		win=window.open ("imanuel.html", "imanuel", "width=180,height=150, screenX=240,screenY=490,resizable=no");
		win.moveTo (250,0)
	}
	
	function fenster18 ()
	{
		var win; 
		win=window.open ("james.html", "james", "width=180,height=150, screenX=420,screenY=490,resizable=no");
		win.moveTo (430,0)
	}
	
	function fenster19 ()
	{
		var win; 
		win=window.open ("jan.html", "jan", "width=180,height=150, screenX=600,screenY=490,resizable=no");
		win.moveTo (610,0)
	}
	
	function fenster20 ()
	{
		var win; 
		win=window.open ("jeanette.html", "jeanette", "width=180,height=150, screenX=780,screenY=490,resizable=no");
		win.moveTo (790,0)
	}
	
	function fenster21 ()
	{
		var win; 
		win=window.open ("lena.html", "lena", "width=180,height=150, screenX=60,screenY=300,resizable=no");
		win.moveTo (250,185)
	}
	
	function fenster22 ()
	{
		var win; 
		win=window.open ("lucie.html", "lucie", "width=180,height=150, screenX=240,screenY=300,resizable=no");
		win.moveTo (430,185)
	}
	
	function fenster23 ()
	{
		var win; 
		win=window.open ("marion.html", "marion", "width=180,height=150, screenX=420,screenY=300,resizable=no");
		win.moveTo (610,185)
	}
	
	function fenster24 ()
	{
		var win; 
		win=window.open ("michael.html", "michael", "width=180,height=150, screenX=600,screenY=300,resizable=no");
		win.moveTo (790,185)
	}
	
	function fenster25 ()
	{
		var win; 
		win=window.open ("milenko.html", "milenko", "width=180,height=150, screenX=780,screenY=300,resizable=no");
		win.moveTo (250,370)
	}
	
	function fenster26 ()
	{
		var win; 
		win=window.open ("monika.html", "monika", "width=180,height=150, screenX=60,screenY=490,resizable=no");
		win.moveTo (430,370)
	}
	
	function fenster27 ()
	{
		var win; 
		win=window.open ("muda.html", "muda", "width=180,height=150, screenX=240,screenY=490,resizable=no");
		win.moveTo (610,370)
	}
	
	function fenster28 ()
	{
		var win; 
		win=window.open ("nathalie.html", "nathalie", "width=180,height=150, screenX=420,screenY=490,resizable=no");
		win.moveTo (790,370)
	}
	
	function fenster29 ()
	{
		var win; 
		win=window.open ("rahel.html", "rahel", "width=180,height=150, screenX=600,screenY=490,resizable=no");
		win.moveTo (250,555)
	}
	
	function fenster30 ()
	{
		var win; 
		win=window.open ("reto.html", "reto", "width=180,height=150, screenX=780,screenY=490,resizable=no");
		win.moveTo (430,555)
	}
	
	function fenster31 ()
	{
		var win; 
		win=window.open ("rinny.html", "rinny", "width=180,height=150, screenX=60,screenY=300,resizable=no");
		win.moveTo (610,555)
	}
	
	function fenster32 ()
	{
		var win; 
		win=window.open ("salome.html", "salome", "width=180,height=150, screenX=240,screenY=300,resizable=no");
		win.moveTo (790,555)
	}
	
	function fenster33 ()
	{
		var win; 
		win=window.open ("sandra.html", "sandra", "width=180,height=150, screenX=420,screenY=300,resizable=no");
		win.moveTo (250,0)
	}
	
	function fenster34 ()
	{
		var win; 
		win=window.open ("sarah.html", "sarah", "width=180,height=150, screenX=600,screenY=300,resizable=no");
		win.moveTo (430,0)
	}
	
	function fenster35 ()
	{
		var win; 
		win=window.open ("selia.html", "selia", "width=180,height=150, screenX=780,screenY=300,resizable=no");
		win.moveTo (610,0)
	}
	
	function fenster36 ()
	{
		var win; 
		win=window.open ("silvio.html", "silvio", "width=180,height=150, screenX=60,screenY=490,resizable=no");
		win.moveTo (790,0)
	}
	
	function fenster37 ()
	{
		var win; 
		win=window.open ("sonja.html", "sonja", "width=180,height=150, screenX=240,screenY=490,resizable=no");
		win.moveTo (250,185)
	}
	
	function fenster38 ()
	{
		var win; 
		win=window.open ("valentina.html", "valentina", "width=180,height=150, screenX=420,screenY=490,resizable=no");
		win.moveTo (430,185)
	}
	
	function fenster39 ()
	{
		var win; 
		win=window.open ("vesna.html", "vesna", "width=180,height=150, screenX=600,screenY=490,resizable=no");
		win.moveTo (610,185)
	}
	
	function fenster40 ()
	{
		var win; 
		win=window.open ("nina.html", "nina", "width=180,height=150, screenX=780,screenY=490,resizable=no");
		win.moveTo (790,185)
	}
	
	function fenster41 ()
	{
		var win; 
		win=window.open ("michi.html", "michi", "width=180,height=150, screenX=60,screenY=300,resizable=no");
		win.moveTo (250,370)
	}
	
	*/
