// JavaScript Document
$(document).ready(function(){
	$.gaTracker('UA-3857475-4');
	$('.altContent').hide();
	var foot = $("#columnLeft_shoe").remove();
	/*embed flash */
	$("#seeBlueFlash").flashembed({src:"flash/seeBlue.swf",width:"955",height:"600",wmode:"transparent"});
	$("#catsLifeFlash").flashembed({src:"/flash/catsLife.swf",width:"955",height:"600",wmode:"transparent"});
	$('.flashWrap').append(foot);
	var yOffset = Math.round(($(window).height() - 600)/2)-20
	if(yOffset < 0)
	{
		yOffset = 0;
	}
	var xOffset = Math.round(($(window).width() - 955)/2)
	if(xOffset < 0)
	{
		xOffset = 0;
	}
	$(".flashWrap").attr("style", "top:"+yOffset+"px;left:"+xOffset+"px;");
	var bgxOffset = Math.round(($(window).width() - 1820)/2)
	var bgyOffset = Math.round(($(window).height() - 1730)/2)
	$("body.flashPage").attr("style", "background-position:"+bgxOffset+"px "+bgyOffset+"px;");
	$('.flashWrap').css({'display':'block'})
});
$(window).resize(function () { 
	yOffset = Math.round(($(window).height() - 600)/2)-20
	if(yOffset < 0)
	{
		yOffset = 0;
	}
	xOffset = Math.round(($(window).width() - 955)/2)
	if(xOffset < 0)
	{
		xOffset = 0;
	}
	$(".flashWrap").attr("style", "top:"+yOffset+"px;left:"+xOffset+"px;").css({'display':'block'});
	bgxOffset = Math.round(($(window).width() - 1820)/2)
	bgyOffset = Math.round(($(window).height() - 1730)/2)
	$("body.flashPage").attr("style", "background-position:"+bgxOffset+"px "+bgyOffset+"px;");
});
