var _brw = getBrowserName();
var _ieversion = getIEVersion();

window.onresize = function(){
	if (_ieversion < 8){
		if (_brw == "MSIE" || _brw == "Safari" || _brw == "Opera"){
			location.reload();
		}else{
			resizeFla();
		}
	}else{
		resizeFla();
	}
}

window.onload = function(){
	resizeFla();
}

function resizeFla(){
	var theMovie;
	if (_brw == "MSIE"){
		theMovie = document.getElementById('theMovie');
	}else{
		theMovie = document.embeds['theMovie'];
	}
	var win_width = document.body.clientWidth;
	var win_height = document.documentElement.clientHeight;

	if (_brw == "Firefox" || _ieversion >= 8){
		win_width = win_width - 20;
		win_height = win_height - 20;
	}

	if (document.getElementById('flaTirashi')){
		var fla_y = document.getElementById('flaTirashi').offsetTop;
		var fla_height = win_height - fla_y;
		theMovie.setAttribute("width",win_width);
		theMovie.setAttribute("height",fla_height);
		if (_brw == "Firefox"){
			theMovie.src = theMovie.src;
		}
	}

}

function funcWindow(url) {
	x = 100;
	y = 100;
	window.open(url,"","location=no,menubar=no,resizable=yes,scrollbars=yes,left=" + x + ",top=" + y + ",width=720,height=480","");
}

