//copyright   : (c) macrocom gmbh
//description : html-seiten im extra popup-fenster öffnen 
//
        
  // posistionerung des popups
  //var xpos =  10;
  var ypos =  0;
  var new_Window = null;        
           
function mac_Fenster2(WinWidth,WinHeight,Link,WindowName)
{
   var xpos = screen.width-WinWidth-15;
   //Height = screen.availHeight - 28;
	Height = WinHeight;
   //Ansicht-Fenster auf jeden Fall schliessen, wenn noch offen   
   mac_WindowClose();
  
   new_Window = window.open(Link,WindowName,'toolbar=0,width='+WinWidth+',height='+Height+',location=0,directories=0,status=0,menubar=0,scrollbars=yes,resizable=0,copyhistory=0,left='+xpos+',top='+ypos);
   new_Window.focus();
}

function mac_Fenster(WinWidth,WinHeight,Link,WindowName)
{
   var xpos = screen.width-WinWidth-15;

   //Ansicht-Fenster auf jeden Fall schliessen, wenn noch offen   
   mac_WindowClose();
  
   new_Window = window.open(Link,WindowName,'toolbar=0,width='+WinWidth+',height='+WinHeight+',location=0,directories=0,status=0,menubar=0,scrollbars=yes,resizable=0,copyhistory=0,left='+xpos+',top='+ypos);
   new_Window.focus();
}

//Ansicht-Fenster auf jeden Fall schliessen, wenn noch offen
function mac_WindowClose()
{
   if (new_Window != null)
     if (!new_Window.closed)
       new_Window.close();
}

function mac_Fensteredit(WinWidth,WinHeight,Link,WindowName)
{

 //  alert("Link = " + Link);
   var xpos = 0;
   Height = screen.availHeight - 28;
	Height = WinHeight;
  
//   alert("Height = " + Height);
   //Ansicht-Fenster auf jeden Fall schliessen, wenn noch offen   
    mac_WindowClose();
  
   new_Window = window.open(Link,WindowName,'toolbar=0,width='+WinWidth+',height='+Height+',location=0,directories=0,status=0,menubar=0,scrollbars=no,resizable=0,copyhistory=0,left='+xpos+',top='+ypos);
//   alert("Hier ist Ende");

   new_Window.focus();
}
function getLeft(l)
		{
		  if (l.offsetParent) return (l.offsetLeft + getLeft(l.offsetParent));
		  else return (l.offsetLeft);
		}
function getTop(l)
		{
		  if (l.offsetParent) return (l.offsetTop + getTop(l.offsetParent));
		  else return (l.offsetTop);
		}



function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

function mac_editdatei(WinWidth,WinHeight,Link,WindowName)
{

 //  alert("Link = " + Link);
   var xpos = 0;
   Height = screen.availHeight - 28;

//   alert("Height = " + Height);
   //Ansicht-Fenster auf jeden Fall schliessen, wenn noch offen   
   mac_WindowClose();
  
   new_Window = window.open(Link,WindowName,'toolbar=0,width='+WinWidth+',height='+WinHeight+',location=0,directories=0,status=0,menubar=0,scrollbars=no,resizable=0,copyhistory=0,left='+xpos+',top='+ypos);
//   alert("Hier ist Ende");

   new_Window.focus();
}
