
if ( !window.current_content ) {
	window.current_content = "home";
}

check_query = function() {
	var query_string = window.location.href;
	var qcharidx = query_string.lastIndexOf("?");
	
	if ( qcharidx != -1) {
		var thepage = query_string.substring(qcharidx+1);
		
		switch (thepage) {
			
			case "home":
			case "guide":
			case "release":
			case "contact":
				toggle_content(thepage);
				break;
		}
	}
}

toggle_content = function(switch_to) {
	
	if ( switch_to != window.current_content ) {

		$(switch_to + '_link').style.color = "#D6D6D6";
		$(window.current_content + '_link').style.color = "#000";

		$(current_content).style.display = 'none';
		Effect.Appear(switch_to, {duration:1});
		window.current_content = switch_to;
	}
}

toggle_screenshot = function(img_path, wide) {

  var windowWidth = 0;
  if( typeof( window.innerWidth ) == 'number' ) {
    //Non-IE
    windowWidth = window.innerWidth;
  } else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) ) {
    //IE 6+ in 'standards compliant mode'
    windowWidth = document.documentElement.clientWidth;
  } else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) ) {
    //IE 4 compatible
    windowWidth = document.body.clientWidth;
  }
	
	// new Effect.Move($("ss"), {x: ((windowWidth)/2) - (340/2), y:50, mode: 'absolute'});
	divname = "ss";
	if ( wide ) {
		divname = "ssw";
		$(divname).style.top = "50px";
	 	$(divname).style.left = ((windowWidth)/2) - (490/2) + "px"
		$("ssw_img").innerHTML = "<img src='" + img_path + "'>";
	}
	else {
		$(divname).style.top = "50px";
	 	$(divname).style.left = ((windowWidth)/2) - (340/2) + "px"
		$("ss_img").innerHTML = "<img src='" + img_path + "'>";
	}
	// $("ss").style.display = "inline";


	new Effect.Appear(divname, {duration:.5});
}