/**
 * Berechnung der Menue postition unbhängig von der Auflösung
 * Jedoch gibt es einen Interpretationsunterschied zwischen MS Exp. und Mozilla
 * und zudem noch Berechnungsschwierigkeiten für Mozilla. Daher optimal für 1024 x 768
 * und Aufflösungen im selben Verhältniss
 */

var hoch = screen.height;
var breit = screen.width;

if (navigator.appName.indexOf("Explorer") != -1){
		Faktor_B = (screen.width - 800 - 18) / 2 ;
		Faktor_A = (screen.height - 570) /2 + 44;
}
else{
		Faktor_B = (screen.width - 800) / 2;
		Faktor_A = (screen.height - 570) /2 + 38;
}

/*  Popup für das Impressum / popup_imp() */
function popup_imp(){ 
	window.open('impressum.htm','displayWindow','toolbar=no,width=420,height=640,directories=no,status=no,scrollbars=no,resize=no,menubar=no')
} 

/*  Popup für den Verkauf Hochauflösendes Bild*/
function popup_verkauf(url){
	var generator=window.open('','name','height=800,width=600');
	generator.document.write('<html><head><title>Zum Verkauf bei Firma A.Bernhold</title>');
	generator.document.write('<link rel="stylesheet" href="style.css">');
	generator.document.write('</head><body background="'+url+'">');
	generator.document.write('<img src="bilder/transp.gif" height="100%" width="100%" alt="copyright by A.Bernhold">');
	generator.document.write('</body></html>');
	generator.document.close();
}

function popup_stern(url){
	var generator=window.open('','name','height=825,width=600');
	generator.document.write('<html><head><title>Firma A.Bernhold im Stern</title>');
	generator.document.write('<link rel="stylesheet" href="style.css">');
	generator.document.write('</head><body background="'+url+'">');
	generator.document.write('<img src="bilder/transp.gif" height="100%" width="100%" alt="copyright by A.Bernhold">');
	generator.document.write('</body></html>');
	generator.document.close();
}

/*  Popup für den Meisterbrief/ popup_mbrief() */
function popup_mbrief(){ 
	window.open('mbrief.htm','displayWindow','toolbar=no,width=300,height=472,directories=no,status=no,scrollbars=no,resize=no,menubar=no')
} 

/* Links der Menue Leiste kann hiererweitert weden um das Meune auf allen Seiten zu erweitern/ mmLoadMenus() */
			function mmLoadMenus() {
  				if (window.mm_menu_Kollektion_0) return;
  					window.mm_menu_Kollektion_0 = new Menu("root",98,17,"Arial, Helvetica, sans-serif",11,"#000000","#FFFFFF","#ABABAB","#ABABAB","center","middle",1,0,1000,0,0,true,true,false,0,true,true);
  					mm_menu_Kollektion_0.addMenuItem("Automatic","location='automa.htm'");
  					mm_menu_Kollektion_0.addMenuItem("Chronographen","location='chrono.htm'");
					mm_menu_Kollektion_0.addMenuItem("Stimmgabel","location='stimm.htm'");
					mm_menu_Kollektion_0.addMenuItem("Handaufzug","location='hand.htm'");
					mm_menu_Kollektion_0.addMenuItem("Quartz","location='quartz.htm'");
					mm_menu_Kollektion_0.addMenuItem("Sondermodelle","location='sonder.htm'");
					mm_menu_Kollektion_0.addMenuItem("Taschenuhren","location='taschen.htm'");
					mm_menu_Kollektion_0.addMenuItem("Damenuhren","location='damen.htm'");
				
					window.mm_menu_Reparatur_0 = new Menu("root",98,17,"Arial, Helvetica, sans-serif",11,"#000000","#FFFFFF","#ABABAB","#ABABAB","center","middle",1,0,1000,0,0,true,true,false,0,true,true);
  					mm_menu_Reparatur_0.addMenuItem("Armbanduhren","location='rep_arm.htm'");
  					mm_menu_Reparatur_0.addMenuItem("Standuhren","location='rep_stand.htm'");
					mm_menu_Reparatur_0.addMenuItem("Meisterbrief","window.open('mbrief.htm','displayWindow','toolbar=no,width=300,height=472,directories=no,status=no,scrollbars=no,resize=no,menubar=no')");
				
					window.mm_menu_Kontakt_0 = new Menu("root",98,17,"Arial, Helvetica, sans-serif",11,"#000000","#FFFFFF","#ABABAB","#ABABAB","center","middle",1,0,1000,0,0,true,true,false,0,true,true);
  					mm_menu_Kontakt_0.addMenuItem("Mail","location='mail.htm'");
  					mm_menu_Kontakt_0.addMenuItem("Anfahrt","location='anfahrt.htm'");
    				mm_menu_Kontakt_0.writeMenus();

				} // mmLoadMenus() 
				
/* RechtsKlick Sperre */
  function right(e) {
  if (navigator.appName == 'Netscape' && 
  (e.which == 3 || e.which == 2))
  return false;
  else if (navigator.appName == 'Microsoft Internet Explorer' && 
  (event.button == 2 || event.button == 3)) {
  alert("© 2009 by Uhrmachermeister A.Bernhold");
  return false;
  }
  return true;
  }
  document.onmousedown=right;
  if (document.layers) window.captureEvents(Event.MOUSEDOWN);
  window.onmousedown=right;