/*******************************************************************************

FILE: mud_Scripts.js
REQUIRES: prototype.js
AUTHOR: Takashi Okamoto mud(tm) - http://www.mudcorp.com/
VERSION: 2.1 - update to make it work more like MudFadeGallery
DATE: 04/07/2006

--------------------------------------------------------------------------------

This file is part of MudShiftContent.

	MudShiftContent is free for anyone to use, but this header MUST be
	included, and may not be modified.

*******************************************************************************/

////////////////////////////////////////////////////////////////////////////////
// GLOBAL VARS

var imgs;
var imgsGallery = new Array();

////////////////////////////////////////////////////////////////////////////////
// MOUSE EVENTS

function setOnMouseClick() {
	var elements = document.getElementsByTagName("a");
	for (var i = 0; i < elements.length; i++) {
		switch(elements[i].className) {
			case "next":
				elements[i].onclick = function() {
					 imgs.move('next');
					 return false;
				}
				break;
			case "prev":
				elements[i].onclick = function() {
					 imgs.move('prev');
					 return false;
				}
				break;
		}
	}
}

////////////////////////////////////////////////////////////////////////////////
// INIT

if (navigator.appName == 'Microsoft Internet Explorer' || screen.width <= 1280) {var init = function () {
	setOnMouseClick();
	// images gallery
	imgsGallery[0] = new Object();
	imgsGallery[0].image = new Image;
	imgsGallery[0].image.src = "images/hochzeit1/quer.jpg";
	imgsGallery[0].caption = "1/11";
	
	imgsGallery[1] = new Object();
	imgsGallery[1].image = new Image;
	imgsGallery[1].image.src = "images/hochzeit1/hoch.jpg";
	imgsGallery[1].caption = "2/11";
	
	imgsGallery[2] = new Object();
	imgsGallery[2].image = new Image;
	imgsGallery[2].image.src = "images/hochzeit1/quad.jpg";
	imgsGallery[2].caption = "3/11";
	
	imgsGallery[3] = new Object();
	imgsGallery[3].image = new Image;
	imgsGallery[3].image.src = "images/hochzeit1/quer.jpg";
	imgsGallery[3].caption = "4/11";
	
	imgsGallery[4] = new Object();
	imgsGallery[4].image = new Image;
	imgsGallery[4].image.src = "images/hochzeit1/quer.jpg";
	imgsGallery[4].caption = "5/11";
	
	imgsGallery[5] = new Object();
	imgsGallery[5].image = new Image;
	imgsGallery[5].image.src = "images/hochzeit1/hoch.jpg";
	imgsGallery[5].caption = "6/11";
	
	imgsGallery[6] = new Object();
	imgsGallery[6].image = new Image;
	imgsGallery[6].image.src = "images/hochzeit1/hoch.jpg";
	imgsGallery[6].caption = "7/11";
	
	imgsGallery[7] = new Object();
	imgsGallery[7].image = new Image;
	imgsGallery[7].image.src = "images/hochzeit1/quer.jpg";
	imgsGallery[7].caption = "8/11";
	
	imgsGallery[8] = new Object();
	imgsGallery[8].image = new Image;
	imgsGallery[8].image.src = "images/hochzeit1/quer.jpg";
	imgsGallery[8].caption = "9/11";
	
	imgsGallery[9] = new Object();
	imgsGallery[9].image = new Image;
	imgsGallery[9].image.src = "images/hochzeit1/hoch.jpg";
	imgsGallery[9].caption = "10/11";
	
	imgsGallery[10] = new Object();
	imgsGallery[10].image = new Image;
	imgsGallery[10].image.src = "images/hochzeit1/quer.jpg";
	imgsGallery[10].caption = "11/11";
	
	
	// MudShiftContent(id, unitX, unitTotal)
	imgs = new MudShiftContent('imgs', imgsGallery);
	
	// set init
	if ($('imgs_title')) $('imgs_title').innerHTML = imgsGallery[0].title;
	if ($('imgs_caption')) $('imgs_caption').innerHTML = imgsGallery[0].caption;
}
}
if (navigator.appName != 'Microsoft Internet Explorer' && screen.width > 1280) {var init = function () {
	setOnMouseClick();
	// images gallery
	imgsGallery[0] = new Object();
	imgsGallery[0].image = new Image;
	imgsGallery[0].image.src = "images/hochzeit1/hochzeit1.jpg";
	imgsGallery[0].caption = "1/11";
	
	imgsGallery[1] = new Object();
	imgsGallery[1].image = new Image;
	imgsGallery[1].image.src = "images/hochzeit1/hochzeit2.jpg";
	imgsGallery[1].caption = "2/11";
	
	imgsGallery[2] = new Object();
	imgsGallery[2].image = new Image;
	imgsGallery[2].image.src = "images/hochzeit1/hochzeit3.jpg";
	imgsGallery[2].caption = "3/11";
	
	imgsGallery[3] = new Object();
	imgsGallery[3].image = new Image;
	imgsGallery[3].image.src = "images/hochzeit1/hochzeit4.jpg";
	imgsGallery[3].caption = "4/11";
	
	imgsGallery[4] = new Object();
	imgsGallery[4].image = new Image;
	imgsGallery[4].image.src = "images/hochzeit1/hochzeit5.jpg";
	imgsGallery[4].caption = "5/11";
	
	imgsGallery[5] = new Object();
	imgsGallery[5].image = new Image;
	imgsGallery[5].image.src = "images/hochzeit1/hochzeit6.jpg";
	imgsGallery[5].caption = "6/11";
	
	imgsGallery[6] = new Object();
	imgsGallery[6].image = new Image;
	imgsGallery[6].image.src = "images/hochzeit1/hochzeit7.jpg";
	imgsGallery[6].caption = "7/11";
	
	imgsGallery[7] = new Object();
	imgsGallery[7].image = new Image;
	imgsGallery[7].image.src = "images/hochzeit1/hochzeit8.jpg";
	imgsGallery[7].caption = "8/11";
	
	imgsGallery[8] = new Object();
	imgsGallery[8].image = new Image;
	imgsGallery[8].image.src = "images/hochzeit1/hochzeit9.jpg";
	imgsGallery[8].caption = "9/11";
	
	imgsGallery[9] = new Object();
	imgsGallery[9].image = new Image;
	imgsGallery[9].image.src = "images/hochzeit1/hochzeit10.jpg";
	imgsGallery[9].caption = "10/11";
	
	imgsGallery[10] = new Object();
	imgsGallery[10].image = new Image;
	imgsGallery[10].image.src = "images/hochzeit1/hochzeit11.jpg";
	imgsGallery[10].caption = "11/11";
	
	
	// MudShiftContent(id, unitX, unitTotal)
	imgs = new MudShiftContent('imgs', imgsGallery);
	
	// set init
	if ($('imgs_title')) $('imgs_title').innerHTML = imgsGallery[0].title;
	if ($('imgs_caption')) $('imgs_caption').innerHTML = imgsGallery[0].caption;
}
}
////////////////////////////////////////////////////////////////////////////////
// EVENTS

Event.observe(window, 'load', init, false);
