// JavaScript Document
function toggleBox(szDivID, iState) // 1 visible, 0 hidden
{
   	if(document.layers)	   //NN4+
    {	
		if (document.layers[szDivID])
		{
			document.layers[szDivID].visibility = iState ? "show" : "hide";
		}
    }
    else if(document.getElementById)	  //gecko(NN6) + IE 5+
    {
		if(document.getElementById(szDivID))
		{	
	        var obj = document.getElementById(szDivID);
    	    obj.style.visibility = iState ? "visible" : "hidden";
		}
    }
    else if(document.all)	// IE 4
    {
		if(document.all[szDivID])
		{
	        document.all[szDivID].style.visibility = iState ? "visible" : "hidden";
		}
    }
}


function menu_galerie()
{
	toggleBox('slidegallery',1); 			// Hintergrund an
	toggleBox('gallerybackground',1); 		// Hintergrund an
	toggleBox('gallery',1); 				// RootGalerieansicht an
	toggleBox('gallerymenu',1); 			// Root-Close-Button an

	toggleBox('slidesubgallery',0); 		// Hintergrund aus
	toggleBox('subgallerybackground',0); 	// Hintergrund aus
	toggleBox('subgallery',0); 				// SubGalerieansicht aus
	toggleBox('subgallerymenu',0); 			// Sub-Close-Button aus

	toggleBox('slidethumbs',0); 			// Hintergrund aus
	toggleBox('thumbsbackground',0); 		// Hintergrund aus
	toggleBox('thumbs',0); 					// Vorschauansicht aus
	toggleBox('thumbsmenu',0); 				// Close-Button aus
}

function menu_subgalerie()
{
	toggleBox('slidegallery',0); 			// Hintergrund aus
	toggleBox('gallerybackground',0); 		// Hintergrund aus
	toggleBox('gallery',0); 				// Galerieansicht aus
	toggleBox('gallerymenu',0); 			// Close-Button aus

	toggleBox('slidesubgallery',1); 		// Hintergrund an
	toggleBox('subgallerybackground',1); 	// Hintergrund an
	toggleBox('subgallery',1); 				// SubGalerieansicht an
	toggleBox('subgallerymenu',1); 			// Sub-Close-Button an

	toggleBox('slidethumbs',0); 			// Hintergrund aus
	toggleBox('thumbsbackground',0); 		// Hintergrund aus
	toggleBox('thumbsmenu',0); 				// Close-Button aus
	toggleBox('thumbs',0); 					// Vorschauansicht aus
}

function menu_thumbs()
{
	toggleBox('slidegallery',0); 			// Hintergrund aus
	toggleBox('gallerybackground',0); 		// Hintergrund aus
	toggleBox('gallery',0); 				// RootGalerieansicht aus
	toggleBox('gallerymenu',0); 			// Root-Close-Button aus

	toggleBox('slidesubgallery',0); 		// Hintergrund aus
	toggleBox('subgallerybackground',0); 	// Hintergrund aus
	toggleBox('subgallery',0); 				// SubGalerieansicht aus
	toggleBox('subgallerymenu',0); 			// Sub-Close-Button aus

	toggleBox('slidethumbs',1); 			// Hintergrund an
	toggleBox('thumbsbackground',1); 		// Hintergrund an
	toggleBox('thumbs',1); 					// Vorschauansicht aus
	toggleBox('thumbsmenu',1); 				// Close-Button an
}

function menu_close()
{
	toggleBox('slidegallery',0); 			// Hintergrund aus
	toggleBox('gallerybackground',0); 		// Hintergrund aus
	toggleBox('gallery',0); 				// RootGalerieansicht aus
	toggleBox('gallerymenu',0); 			// Root-Close-Button aus

	toggleBox('slidesubgallery',0); 		// Hintergrund aus
	toggleBox('subgallerybackground',0); 	// Hintergrund aus
	toggleBox('subgallery',0); 				// SubGalerieansicht aus
	toggleBox('subgallerymenu',0); 			// Sub-Close-Button aus

	toggleBox('slidethumbs',0); 			// Hintergrund an
	toggleBox('thumbsbackground',0); 		// Hintergrund aus
	toggleBox('thumbs',0); 					// Vorschauansicht aus
	toggleBox('thumbsmenu',0); 				// Close-Button an
}

function gehtnicht() {
	alert ("Urheberrecht: Sämtliche Fotos sind Eigentum von Maik Schulze, NinePixel.de. Die Verwendung oder Vervielfältigung in anderen elektronischen oder gedruckten Publikationen ist ohne ausdrückliche Zustimmung nicht gestattet.");
	return false;
}

function sperre() {
	document.body.oncontextmenu = gehtnicht;
	document.body.onselectstart = gehtnicht;
	document.body.onkeydown = gehtnicht;
}

function FotoSichtbar()
{
//	sperre();
	imageId ='PhotoDiv';
	image = document.getElementById(imageId);
	image.style.visibility = 'visible';
}


function jstest_fotoload()
{
    document.writeln('<style type="text/css">');
//	document.writeln('/*<![CDATA[*/');
	document.writeln('<!--');
    document.writeln('#keinjavascript{ visibility:hidden;}');
    document.writeln('#PhotoDiv {visibility:hidden;}');			// Fotos ausblenden //
    document.writeln('-->');
//	document.writeln('/*]]>*/');
	document.writeln('</style>');
}
