var minHeight = 740;
var scroll;
var params = {
	allowScriptAccess: "always",
	allowFullScreen: "true",
	wmode: "opaque",
	scale: "noscale",
	bgcolor: "#000000"
};
var attributes = {
	id: "DDB",
	name: "DDB"
};
var flashvars = {
	path: "xml/"
}
var mod = 0;
function init() {
	if (Browser.Engine.gecko && Browser.Platform.mac && window.location.host.indexOf("www")==-1) {
		mod = 350;
	}
	scroll = new Fx.Scroll(window,{
		duration: 800,
		transition: Fx.Transitions.Quint.easeOut
	});
	window.addEvent('scroll',scrollChange);
	swffit.showScrollV();
	swfobject.embedSWF("Preloader.swf", "swfContainer", "100%", "100%", "9.0.0", "flash/expressInstall.swf", flashvars, params, attributes);
	//swffit.fit("DDB", 1024, minHeight);
	SWFAddress.addEventListener(SWFAddressEvent.CHANGE,resetY);
}
function resetY() {
	window.scrollTo(0,0);
}
function setHeight(value) {
	value = parseInt(value) + mod;
	if (value < getHeight()) {
		value = getHeight();
	}
	$('resizer').setStyle('height',value+"px");
}
function reset() {
	var height = "100%";
	if (getHeight()<minHeight) height = minHeight;
	//var height = getHeight();
	//if (height<minHeight) height = minHeight;
	$('resizer').setStyle('height',height);
}
function scrollChange() {
	$('DDB').setScroll(window.getScroll().y);
}
function getHeight() {
	return window.getSize().y;
}
window.addEvent('domready',init);