/***************************************************************
* Funções para inserir flash e video passo tamnho e o endereço *
*                                                              *
* @author Thomaz Takashi Oda Toyama                            *
****************************************************************/
function ClassFLWP(width, height, url){
	this.width 	= width;
	this.height = height;
	this.url 	= url;

	this.openFlash();
}

ClassFLWP.prototype.openFlash = function (){
		document.write('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" ');
		document.write('codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" ');
		document.write('width="'+this.width+'" height="'+this.height+'">');
		document.write('<param name="movie" value="'+this.url+'" />');
		document.write('<param name="wmode" value="transparent" />');
		document.write('<param name="quality" value="high" />');
		document.write('<embed src="'+this.url+'" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" ');
		document.write(' wmode="transparent" type="application/x-shockwave-flash" width="'+this.width+'" height="'+this.height+'"></embed>');
		document.write('</object>')
}

function play( width, height, url ){
	this.width 	= width;
	this.height = height;
	this.url	= url;

	this.openPlay();
}

play.prototype.openPlay = function(){

	document.write( '<object id="WMPlay" width="'+this.width+'" height="'+this.height+'" classid="clsid:22D6F312-B0F6-11D0-94AB-0080C74C7E95"codebase="http://activex.microsoft.com/activex/%20%20%20controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701" standby="Carregando" type="application/x-oleobject" viewastext>' );
	document.write( '<param name="FileName" value="'+this.url+'">' );
	document.write( '<param name="AutoStart" value="True">' );
	document.write( '<param name="TransparentAtStart" value="True">' );
	document.write( '<param name="ShowControls" value="1">' );
	document.write( '<param name="ShowDisplay" value="0">' );
	document.write( '<param name="ShowStatusBar" value="1">' );
	document.write( '<param name="AutoSize" value="0">' );
	document.write( '<param name="AnimationAtStart" value="true">' );
	document.write( '<embed type="application/x-mplayer2" id="MediaPlayer" name="WMPlay" src="'+this.url+'" autostart="0" transparentatstart="0" showcontrols="0" showdisplay="0" showstatusbar="1" animationatstart="0" width="'+this.width+'" height="'+this.height+'"></embed>' );
	document.write( '</object>' );
}
