// JavaScript Document
function $GE(id)
{
	return document.getElementById(id);
}

function simplePreload(){ 
  var args = simplePreload.arguments;
  document.imageArray = new Array(args.length);
  for(var i=0; i<args.length; i++){
    document.imageArray[i] = new Image;
    document.imageArray[i].src = args[i];
  }
}

function StartPage() {
	$GE('preload').style.display = 'none';
	$GE('page').style.display = 'block';
}

function ShowHide(str, str2) {
	if ($GE(str).style.display == 'none'){
		$GE(str).style.display = 'block';
		$GE(str2).style.display = 'none';
	} else {
		$GE(str).style.display = 'none';
		$GE(str2).style.display = 'block';
	}
}

function ShowHideSmooth(str, str2) {
	if ($GE(str).style.display == 'none'){
		/*
		var Lv = 30;
		alpha = new OpacityTween($GE(str),Tween.regularEaseOut, 0, 100, .5);
		alpha.onMotionChanged = function(){
		   $GE(str).style.left = Lv + 'px';
		   Lv += (0 - Lv)/2;
		};
		alpha.onMotionFinished = function(){
		   $GE(str).style.left = 0 + 'px';
		};
		alpha.start();
		*/
		$GE(str).style.display = 'block';
		$GE(str2).style.display = 'none';
	} else {
		$GE(str).style.display = 'none';
		$GE(str2).style.display = 'block';
	}
}

function Show(str) {
	if ($GE(str).style.display == 'none'){
		/*
		alpha = new OpacityTween($GE(str),Tween.regularEaseOut, 0, 100, .5);
		alpha.start();
		*/
		$GE(str).style.display = 'block';
	} else {
		$GE(str).style.display = 'none';
	}
}

function Hide(str) {
	$GE(str).style.display = 'none';
}
function stopHead() {    
	$GE("head").SetVariable("message", "stop");
}
function stopVideo(id) {    
	$GE(id).SetVariable("message", "stop");
}
