

						
function vmePlayer(contentId, boxContent)
{
	var me = this;
	
	this.contentId = contentId;
	this.boxContent = boxContent;
	this.videoInnerHtml = document.getElementById(this.boxContent).innerHTML;
	this.player = null;
	
	this.reinit = function()
	{
		document.getElementById(me.boxContent).innerHTML = me.videoInnerHtml;
		me.init();
	};
	
	
	this.play = function()
	{
		me.player.play();
	}
	
	this.init = function()
	{
		me.player = flowplayer( me.contentId, "/player/flowplayer-3.1.1.swf", { 
			
				Clip: {
					autoPlay: true, 
					autoBuffering: true
				},
						
				plugins:  {  
			        controls:  { 
			            backgroundColor: '#3B3B3B', 
			            backgroundGradient: [0.1,0.2,0.2,0.2,0.2,0,0,0,0,0.2],             
			            all: false, 
			            play: true,
			            volume: false,
			            scrubber: true, 
			            height: 28, 
			            sliderColor: '#FA5505', 
			            progressColor: '#B11007', 
			            bufferColor: '#FA5505' ,
			         	buttonColor: '#FA5505',
			         	buttonOverColor: '#FED281',
			         	autoHide: 'always',
			         	hideDelay: 1000
			      },
			    
			
				 	time: { 
			            url: '/player/flowplayer.controls-3.1.1.swf', 
			            top:0, 
			            backgroundGradient: 'none', 
			            backgroundColor: 'transparent', 
			            buttonColor: '#254558', 
			            timeColor: '#EC3C12',
			         	timeBgColor: '#3B3B3B',
			            all: false, 
			            time: true, 
			            height:30, 
			            right:15, 
			            width:80,
			         	timeBorderRadius: 10
			        }
				},
			     
			    // fiercy red background color with a little gradient and curving 
			    canvas: { 
			        backgroundColor: '#FFFFFF', 
			        backgroundGradient: 'none', 
			        borderRadius: 0
			    }
			}
		
		);
	};
	
	this.init();
}
