// JavaScript Document
function aboutLinksSetup() {
	var aboutLinks = $('aboutList').getElementsByTagName('a');
	for (var i = 0; i < aboutLinks.length; i++) {
		aboutLinks[i].onclick = function() {
			currentId = this.id.substr(9,1);
			textArea = 'aboutInner' + currentId;
			if (document.getElementsByClassName('aboutInnerSelected').length > 0) {
				new Effect.Fade(document.getElementsByClassName('aboutInnerSelected')[0], {
					duration: 0.5,
					afterFinish: function() {
						document.getElementsByClassName('aboutInnerSelected')[0].className = "aboutInner";
						$(textArea).className = "aboutInnerSelected";
						new Effect.Appear(textArea, {
							duration: 0.5
						});
					}
				});
			} else {
				$(textArea).className = "aboutInnerSelected";
				new Effect.Appear(textArea, {
					duration: 0.5
				});
			}
			return false;
		}
	}
}

function luupLinksSetup() {
	var luupLinks = $('luupList').getElementsByTagName('a');
	for (var i = 0; i < luupLinks.length; i++) {
		luupLinks[i].onclick = function() {
			currentId = this.id.substr(8,1);
			//alert(currentId);
			textArea = 'luupInner' + currentId;
			if (document.getElementsByClassName('luupInnerSelected').length > 0) {
				new Effect.Fade(document.getElementsByClassName('luupInnerSelected')[0], {
					duration: 0.5,
					afterFinish: function() {
						document.getElementsByClassName('luupInnerSelected')[0].className = "luupInner";
						$(textArea).className = "luupInnerSelected";
						new Effect.Appear(textArea, {
							duration: 0.5
						});
					}
				});
			} else {
				$(textArea).className = "luupInnerSelected";
				new Effect.Appear(textArea, {
					duration: 0.5
				});
			}
			return false;
		}
	}
}