/**
This will set the swf container to either its minimum height (which is the total height of the swf as built) or 100% width and height if viewable space allows.  Always manually set your min-height as the value of "swfMinHeight"
*/

function setSwfSize() {
	
	w = $(window).width();
	h = $(window).height();
		
	swfMinWidth = 1200;
	swfMinHeight = 1350;
	swfMinHeight2 = 850;
	
	if (swfMinWidth > w ) {
		$('#swfwrapper').width(swfMinWidth);
		$.scrollTo('50%' , { axis:'x' });
	} else {
		$('#swfwrapper').css({ width: '100%' });
	}
	
	if (swfMinHeight > h ) {
		$('#swfwrapper').height(swfMinHeight);
		if (swfMinHeight2 > h) $.scrollTo('14%' , { axis:'y' });
		else $.scrollTo(0 , { axis:'y' });
	} else {
		$('#swfwrapper').height(h);
		$.scrollTo(0 , { axis:'y' });
	}
	
};


$(window).resize(function(){
	setSwfSize();
});



