/*
	Summary		: Script that generates a movie player with a controller
	Started 	: 19/12/2007
	Version 	: 
*/
	var OW_OraoWeb_Player, OW_OraoWeb_version, OW_OraoWeb_version_release_date, OW_OraoWeb_host, flashObjectIsReadyToBeCalled, defaultNameOfOraoWebObject;
	OW_OraoWeb_version				= '3.2.21';
	OW_OraoWeb_version_release_date	= '17/10/09';
	OW_OraoWeb_host					= 'http://www.opsomai.eu/data/oraoweb';
	//  OW_OraoWeb_host					= 'http://oraoweb.vrarchitect.net';
/*
	Owner		: Opsomai (http://www.opsomai.com)
	Author		: Pascal Vuylsteker <pascal.vuylsteker@opsomai.com>
	-------------------------------------------------------------------------

	OW_OraoWeb_Player
	
	Description:
	
	Shows a movie player based on Quicktime and Javascript with its controls. 
	When the appropiate option is set, and the media is a sound, a Flash based display is used to show 
	the graph level of the sound in place of the video
	
	Usage:
	
	player = new OW_OraoWeb_Player(container, options)
	
	container	: an 'Prototypejs' object that target a div in which the player will be written (the id of a div !)
	options		: a hash with the following parameters, format: { option1: value1, option2: value2, ... }
	
	  Main ones  :
		url			: the URL of the movie, must start with http:// or be an URL relative to the calling page
		width		: width of the movie
		height		: height of the movie
		
	For a detailled list of the options, see :
	Development version : pseudoEval(OW_OraoWeb_host)/dev3/ow_help.html
	Stable version 		: pseudoEval(OW_OraoWeb_host)/stable3/ow_help.html
	or
	ow_help.html in your own local installation		
	
	When preparing / updating the code, make sure to have a go at JSLint ( http://www.jslint.com/ ) 
	to check for important mistake (right now, this code doesn't pass JSlint entirely
	especially when using Prototype specificties).
	Then use Minification to get a smaller file ( Packer : http://dean.edwards.name/packer/ )
	I used and tested Packer. Another potential option is YUI Compressor, that I used for the css files
	
	One too may want to add on the fly compresion of js and css file by 
	adding the following 2 lines to the apache server conf file
	# MODIF PVK add on the fly compression of js and css files
	AddOutputFilterByType DEFLATE application/javascript
	AddOutputFilterByType DEFLATE text/css
	
*/
// VP 17/10/09 : utilisation arrondi pour le calcul du nombre d'images dans les fonctions de conversion de TC

/*	Some initial setting done before the object is created		*/
/****************************************************************/
flashObjectIsReadyToBeCalled = false;
defaultNameOfOraoWebObject = 'OW_Player'; // Name of the javascript variable that conctain a ref to this object. It will allow flash to access to this object methods
function flashIsReady() {
	flashObjectIsReadyToBeCalled = true;
	return(defaultNameOfOraoWebObject);
}

/*	Extending the PeriodicalExecuter Class from prototype		*/
/****************************************************************/
// Iused to modify directly the prototype code. Now, I just extend the PeriodicalExecuter Prototype class
PeriodicalExecuter.addMethods({
	// Beginning modif pvk
	// Addition PVK : just make sure that the timer is active, in case we stop it earlier
	  start: function() {
	    if (this.timer) {return;}
	    this.registerCallback();
	  },

	// Addition PVK : force a restart : not sure it this is meaningfull for public use, but for 
	// the following additions
	  restart: function() {
	    this.stop();
	    this.registerCallback();
	  },

	// Addition PVK
	  changeFrequency: function(frequency) {
	    this.frequency = frequency;
		// A change of frequency does not imply an automatic restart 
		// (only if the timer was runing at time of the change) 
	    if (this.timer) {this.restart();}
	  },

	// Addition PVK
	  changeCallback: function(callback) {
	    this.callback = callback;
	    this.restart();
	   }
	// End modif pvk
});

/****************************************************************/
/*	Definition of the 	OW_OraoWeb_Player Class					*/
/****************************************************************/

OW_OraoWeb_Player =  Class.create(	{

	/*	Objects and structures										*/
	/****************************************************************/

container					: null	,	// container object
containerName				: ''	,	// $(containerName) => container object
container_width				: 0		,	// Container with as it was right after the launch of the player
										// used when getting back from Full_Screen
offset_width				: 0		,	// Offset between the the with of a window and its inner html width
offset_height				: 0		,	// Offset between the the height of a window and its inner html height
offset_top					: 0		, 	// Offset between what position you set using window.moveTo and the reading you get from 
											// window.screenY or window.screenTop (depending on the browser)
offset_left					: 0		, 	// Offset between what position you set using window.moveTo and the reading you get from 
											// window.screenX or window.screenLeft (depending on the browser)
offset_tl_set				: false ,	// has thoses previous offset been evaluated already ?
inner_width_before_FS		: 0		,	// right before going into Full Screen
inner_height_before_FS		: 0		,
window_position_x_before_FS : 0		,
window_position_y_before_FS	: 0	 	,
player_panel				: null	,	// hierachy of the player :
movie_panel					: null	,	//		container
										//			=>	videoplayer
										//					=>	movieplayer
										//							=>	movie1
										// 			=>	ow_controllerpanel
										// 					=>	tableSlider
										//		sidecommande (not part of the player, but often there)
										
										// Modele of a page :
										// 		+++++++++++++++++++++++++++++++++++++++++++++
										// 		+	Header									+
										// 		+++++++++++++++++++++++++++++++++++++++++++++
										// 		+						+					+
										// 		+		container		+	sidecommande	+
										// 		+						+					+
										//		+++++++++++++++++++++++++++++++++++++++++++++
										
theVideo					: null	,	//	THE QUICKTIME OBJECT : this.theVideo = document.movie1;
	// if one want to replace Quicktime by another techno, one should list the function called to this object
flash_movie					: null	,	// THE FLASH object, when flash is used to represent the sound level graph
controller_panel			: null	,	// The command/controller panel, below the video  = $('ow_controllerpanel')
end_movie_panel				: null	,	// panel displayed when the movie reached the end (if the option doNothingOnMovieFinished is set to false (default))
end_fullscreen_movie_panel	: null	,	// same as end_movie_panel, but used within the new window when the FS is done by opening a new window
debug_panel					: null  ,	// an area below the player used when in debug mode to display debugging info
help_panel					: null	,	// help div, displayed when one clic on the help button. Attached to the object given by 
										// the help_panel_target parameter or to the container if the object is not set
fs_window					: null	,	// Full Screen window IF it is a new window
button_play					: null	,
button_pause				: null	,
button_fast_forward			: null	,
button_fast_reward			: null	,
position_slider				: null	, // slider de la position

/*	Parameters													*/
/****************************************************************/

tooltips 					: null	,	// tooltips Hash Table in the language set by the 'language' parameter
quicktime_version			: null 	,	// version of QT installed on the user machin IF the QT detection is activated
selectionEventHandler		: null	,	// link to the event binded function that deal with a clic on the selection bar when it covers
 										// the navigation bar (IE issue)
theReleaseOfTheJogShuttle	: null	,	// link to the event binded function that release the jog shuttle when the mouse is up
	
// Variable that deal with the restriction of the move  in QTTime
beg_current_selection		: 0		,	// When an extract is selected, should receive the beginning time, 
										// in the movie timescale of the selection, otherwise, TCin ( >= 0)
end_current_selection		: 0		,	// When an extract is selected, should receive the end time, 
										// in the movie timescale of the selection, otherwise, TCout <= the duration of the movie
beg_current_selection_TC	: 0		,	// The litterate TC
end_current_selection_TC	: 0		,	// The litterate TC
beg_current_selection_vis	: 0		,	// Take into account the loading state
end_current_selection_vis	: 0		,	// Take into account the loading state
flag_sub_selection_set		: false	,	// true if a selection smaller that tcin/tcout is set (and the selected bar is showned)	
flag_sub_selection_QT_tmp_unset : false	,	// true if one move outside of an already set selection (while in pause) to be able to grow
tmpMaxTimeLoaded			: 0		,	// Max Time Loaded
tcIN_in_QTTime				: 0		,	// This is TCin , in the in the movie timescale (usually = 0, and >=0 in case of MPEG1 extraction)
tcOUT_in_QTTime				: 0		,	// This is TCout, in the in the movie timescale (usually = duration and <= duration in case of MPEG1 extraction)

button_play_pause_exist		: false ,	// true when a play/pause button had been detected in the template, implying that its state has to be switch each time one modify the rate of the movie
copyright					: null	,	// Info about the player, calculated automatically from the version variables in the header
// Default Generic Options
movie_options: {			// Cf the Configuration Help (parameter 'help' = true) for the option details
	// PRINCIPALES
	url						: ''	,
	preset					: null	,
	sound_level				: false	,	// if true, we are in radio / sound mode, the QT is reduced anf Flash is used
	url_lvl_xml				: ''	,	// url of the xml file converted from the lvl one
	width					: 400	,
	height					: 300	,
	minimum_available_width	: null  ,	// when set,  define the minimum possible width of an orao window
	minimum_available_height: null	,	// when set,  define the minimum possible height of an orao window
	container_width_after_FS: null	,	// when set, define the Orao container width when back from Full Screen
	imageRootURL			: 'ow_images/'			,	// location of the images 
	typeMime				: 'video/quicktime'		,
	should_select_all		: false	,   // if true, a full selection should be set as soon as possible
	config_help				: false	,	// to get the help instead of the player
	help					: false	, 	//	shortcut for config_help
	name					: 'movie1',	// Not yet fully implemented : see movie1 in the code
	flash_movie_name		: 'ow_flash/ow_soundLevel', // 'ow_flash/ow_soundLevel' or 'ow_soundLevel'
	autoplay				: true	,
	webmasterEmail			: null	,
	language				: 'fr'	,	// 'en' or 'fr' to get tooltips in French or English
	debug_mode				: false	,	// if set to true a panel is added that will contain update info
	debug_mode2				: false ,	// if set to true errors are catched and displaied in an alert sheet
	advance_jog_shuttle		: true	, 
	start_the_stepping_after: 0.6	,	// time before the frame by frame start (after the initial step)
	stepping_frequency		: 0.25	,
	// QUICKTIME DETECTION
	expectedQTversion		: '7.2.1'	,
	quicktimeDetection		: true	,
	simulateQTnotAvailable	: false ,
	// FULLSCREEN
	fullscreen				: false	,
	popUpFullscreen			: true	, 
	automaticallyAdjustSize	: true	,	// adjust size of the player when the size of the window change
	urlOfFullscreenPage		: 'ow_template_fullscreen.html'	,	// PHP: document.location.href.gsub(/[#]/, '') + '&FS=on',
	// TIME and TIMECODE
	timecode_lag			: null	, 	// Timecode of the first frame of the video file
	timecode_IN				: null	,   // Timecode of the theoritical begininng of the video (if it could be cropped at any frame) : timecode_IN >= timecode_lag
	timecode_OUT			: null	,   // Timecode of the theoritical end of the video (if it could be cropped at any frame) : timecode_OUT <= timecode of the last frame
	timecode_lag_in_second	: 0		,
	timecode_with_frame		: false	,	// if true, the frame are displayed
	// MOVIE GEOMETRY POSITION
	movie_background_color	: 'black',
	scale					: 'aspect',
	// CALLBACK FUNCTIONS
	onMovieFinished			: null	,	
	onMovieFullScreen		: null	,	
	onMovieEndFullScreen	: null	,
	onMovieScreenSizeChanged: null	,	// When the size of the window is adjusted bu the user
	onLoadingUpdate			: null	,
	onPlayerReady			: null	,
	onSoundBalanceCalled	: null	, 	// if set, the expected function is called wih -128 or +127 
										// when side bsound bouton are pressed -128 : left side 128 : right side
	doNothingOnMovieFinished: false	,
	urlOfReplacementImage	: 'ow_images/videoPlayer/Play.gif'	,
	urlOfEndImage			: 'ow_images/videoPlayer/Play.gif'	,
	//	SOUND
	sound_handle_variable	: true	,
	sound_slider_height		: 20	,
	sound_slider_width		: 270	, 
	sound_balance			: 0		,
	//  GEOMETRY POSITION
	position_slider_width	: 300	,
	selection_adjust_left	: 0		, // Adjustement of the selection bar to take into account thickness of the cursor and usage of boder in the CSS : left = border left
	selection_adjust_cursor	: 7		, // Adjustement of the selection bar to take into account thickness of the cursor and usage of boder in the CSS : cursor width
	selection_adjust_right	: 0		, // Adjustement of the selection bar to take into account thickness of the cursor and usage of boder in the CSS : right = border right
	controller_panel_height	: 60	,
	controller_panel_width	: null	,
	free_vertical_height	: 65	,	// implicitly below
	free_height_above		: 0		,
	window_position_x		: 50	,	// inital popup
	window_position_y		: 50	,
	window_default_width	: 400	,	// initial popup
	window_default_height	: 500	,
	free_lateral_width_in_FS: 0		,
	free_lateral_width		: -1	,	// if <0, then free_lateral_width = free_lateral_width_in_FS
	offset_width			: 0		,	// Offset between the the with of a window and its inner html width ...
	offset_height			: 0		,	// ... as provided by the window calling the player
	code_controller 		: '<!-- Controller Design -->								'	+
	'	<table border="0" cellpadding="0" cellspacing="0" id="tableSlider">			 	'	+
	'		<!-- First Line +++++++++++++++++++++++++++++++++++++++++++++++     -->	 	'	+
	'		<tr id="ligne-one">														 	'	+
	'			<!-- Progress Bar +++++++++++++++++++++++++++++++++++++++++ 	-->	 	'	+
	'			<td id="ow_id_progress_slider" class="controller" colspan="4">	</td> 	'	+
	'			<!-- TimeCode +++++++++++++++++++++++++++++++++++++++++++++ 	-->	 	'	+
	'			<td id="controller-timecode" 										 	'	+
	'			class="controller"><p id="ow_id_timecode">--:--:--</p></td>			 	'	+
	'		</tr>																	 	'	+
	'		<tr id="ligne-two">														 	'	+
	'			<!-- Play  Pause la video +++++++++++++++++++++++++++++++++ 	-->	 	'	+
	'			<td id="navigation-play-pause" class="controller">					 	'	+
	'				<a id="ow_bouton_play"><img/></a>								 	'	+
	'				<a id="ow_bouton_pause"><img/></a>								 	'	+
	'			</td>																 	'	+
	'			<!-- Avance Retour Rapide +++++++++++++++++++++++++++++++++ 	-->	 	'	+
	'			<td id="navigation-fast">											 	'	+
	'				<a id="ow_bouton_fast_rewind"><img/></a> 						 	'	+
	'				<a id="ow_bouton_fast_forward"><img/></a>						 	'	+
	'			</td>																 	'	+
	'			<!-- Full Screen  +++++++++++++++++++++++++++++++++++++++++ 	-->	 	'	+
	'			<td id="navigation-zone-full-screen" class="controller">			 	'	+
	'				<a id="ow_bouton_fullscreen"><img/></a>							 	'	+
	'				<a id="ow_bouton_mute_sound"><img/></a>							 	'	+
	'			</td>																 	'	+
	'			<td id="empty"></td>												 	'	+
	'			<!-- Sound  +++++++++++++++++++++++++++++++++++++++++++++++ 	-->	 	'	+
	'			<td id="ow_id_sound_slider">	</td>								 	'	+
	'		</tr>																	 	'	+
	'	</table>',
	code_panel_end 			: '<a id="ow_image_end_restart_video"><img></a><br><a id="ow_bouton_play_again"><img></a>',
	code_panel_end_FS		: '<a id="ow_image_end_restart_video"><img></a><br><a id="ow_bouton_fullscreen_end"><img/></a> '	+
	'							<a id="ow_bouton_play_again"><img></a>',
	code_end_FS_movie_panel	: '<a id="ow_image_wentFS_restart_video"><img></a><br><a id="ow_bouton_play_again_afterFS"><img></a>',					
	code_panel_help 		: '<div id="ow_help_panel_panel"><h3 id="ow_help_panel_title"> </h3><div id="ow_help_panel_content"> </div></div>',
	help_panel_target		: null	,	// if not null, receive an html object to which the help panel will be attached
	images					: {
		'ow_bouton_play'				: 'Play.gif'			,
		'ow_bouton_pause'				: 'Pause.gif'			,
		'ow_bouton_play_pause'			: 'Play.gif'			,
		'ow_bouton_play_again'			: 'Play.gif'			,
		'ow_bouton_fast_rewind'			: 'FastRewind.gif'		,
		'ow_bouton_fast_forward'		: 'FastForward.gif'		,
		'ow_bouton_step_rewind'			: 'FastRewind.gif'		,
		'ow_bouton_step_forward'		: 'FastForward.gif'		,
		'ow_bouton_go_to_beginning'		: 'FastRewind.gif'		,
		'ow_bouton_go_to_end'			: 'FastForward.gif'		,
		'ow_bouton_fullscreen_open'		: 'CloseFS.gif'			,
		'ow_bouton_fullscreen_close'	: 'CloseFS.gif'			,
		'ow_bouton_mute_sound'			: 'BTsonOff.png'		,				
		'ow_bouton_max_sound'			: 'BTsonOff.png'		,
		'ow_bouton_help'				: 'boutons/b_aide_petit.gif'	,
		'ow_bouton_logo_player'			: 'logo.gif'			,	
		'ow_logo_quicktime'				: 'logo_qtlogo.gif'		,	
		'ow_background_sound_slider'	: 'Sound.gif'			,
		'ow_background_jog_slider'		: 'jogshuttle/barre_jogshuttle.png'		,
		'ow_bouton_beg_selection'		: 'boutons/b_definir_debut_petit.gif'	,	
		'ow_bouton_end_selection'		: 'boutons/b_definir_fin_petit.gif'		,	
		'ow_bouton_save_selection'		: 'boutons/b_disquette_petit.png'		,	
		'ow_bouton_new_selection'		: 'boutons/b_nouv_chap_petit.gif'		,	
		'ow_bouton_annotate_selection'	: 'boutons/b_annoter_petit.gif'
	},
	images_pressed					: {
		'ow_bouton_play'				: 'Play.gif'			,
		'ow_bouton_pause'				: 'Pause.gif'			,
		'ow_bouton_play_pause'			: 'Play.gif'			,
		'ow_bouton_play_again'			: 'Play.gif'			,
		'ow_bouton_fast_rewind'			: 'FastRewind.gif'		,
		'ow_bouton_fast_forward'		: 'FastForward.gif'		,
		'ow_bouton_step_rewind'			: 'FastRewind.gif'		,
		'ow_bouton_step_forward'		: 'FastForward.gif'		,
		'ow_bouton_go_to_beginning'		: 'FastRewind.gif'		,
		'ow_bouton_go_to_end'			: 'FastForward.gif'		,
		'ow_bouton_fullscreen_open'		: 'CloseFS.gif'			,
		'ow_bouton_fullscreen_close'	: 'CloseFS.gif'			,
		'ow_bouton_mute_sound'			: 'BTsonOff.png'		,				
		'ow_bouton_max_sound'			: 'BTsonOff.png'		,
		'ow_bouton_help'				: 'boutons/b_aide_petit.gif'	,
		'ow_bouton_logo_player'			: 'logo.gif'			,	
		'ow_logo_quicktime'				: 'logo_qtlogo.gif'		,	
		'ow_background_sound_slider'	: 'Sound.gif'			,
		'ow_background_jog_slider'		: 'jogshuttle/barre_jogshuttle.png'		,
		'ow_bouton_beg_selection'		: 'boutons/b_definir_debut_petit.gif'	,	
		'ow_bouton_end_selection'		: 'boutons/b_definir_fin_petit.gif'		,	
		'ow_bouton_save_selection'		: 'boutons/b_disquette_petit.png'		,	
		'ow_bouton_new_selection'		: 'boutons/b_nouv_chap_petit.gif'		,	
		'ow_bouton_annotate_selection'	: 'boutons/b_annoter_petit.gif'
	},
	tooltips_fr				: {
		'ow_id_timecode' 				: 'Time Code (HH:mm:ss)',
		'ow_id_timecodeLong' 			: 'Time Code (HH:mm:ss.frame)',
		'ow_id_sound_slider'			: 'Volume sonore',
		'ow_id_progress_slider'			: 'Barre de progression',
		'ow_id_jog_slider'				: 'Jog Shuttle',
		'ow_bouton_play' 				: 'Lecture',
		'ow_bouton_pause' 				: 'Pause',
		'ow_bouton_play_pause' 			: 'Lecture ou Pause (suivant contexte)',
		'ow_bouton_play_again'			: 'Relance la visionneuse',
		'ow_bouton_fast_rewind' 		: 'Retour rapide',
		'ow_bouton_fast_forward' 		: 'Avance rapide',
		'ow_bouton_step_rewind'			: 'Reculer d\'une image',
		'ow_bouton_step_forward'		: 'Avancer d\'une image',
		'ow_bouton_go_to_beginning'		: 'Retourner au début du film',
		'ow_bouton_go_to_end'			: 'Aller à la fin',
		'ow_bouton_fullscreen_open'		: 'Passer en plein écran',
		'ow_bouton_fullscreen_close'	: 'Revenir à la taille normale',
		'ow_bouton_mute_sound' 			: 'Coupe le son',
		'ow_bouton_max_sound' 			: 'Son au maximum',
		'ow_bouton_left_sound'			: 'Entendre uniquement la piste gauche du son'	,
		'ow_bouton_right_sound'			: 'Entendre uniquement la piste droite du son'	,
		'ow_bouton_logo_player'			: 'OraoWeb : Player Quicktime + Javascript ',	
		'ow_selection_start_handle'		: 'Début de l\'extrait',
		'ow_selection_end_handle'		: 'Fin de l\'extrait',
		'ow_bouton_help'				: 'Afficher l\'écran d\'aide',

		'mes_help_title'				: 'Aide',
		'mes_help'						: '<h4>Pour créer vos propres extraits</h4><p>- sélectionnez le début de l\'extrait : cliquez sur ow_bouton_beg_selection<br>- sélectionnez la fin de l\'extrait : cliquez sur ow_bouton_end_selection<br>- saisissez votre titre<br>- sauvegardez votre extrait : cliquez sur ow_bouton_save_selection</p><h4>Pour créer d\'autres extraits, cliquez sur ow_bouton_new_selection</h4><h4>Pour annoter vos extraits, cliquez sur ow_bouton_annotate_selection</h4><h5>[ retour au visionnage ]</h5>',
		'mes_copyright_title'			: 'Orao : Player Quicktime + Javascript ',
		'mes_copyright'					: 'Orao : Player QuickTime. Ver.'+ OW_OraoWeb_version +' ('+OW_OraoWeb_version_release_date+'). Copyright Opsomai',

		'mes_plugin_not_yet_ready'		: 'Il semble que votre navigateur n\'ai pas réussit à se connecter au plug-in video. Ceci peut être du à un ordinateur relativement lent. Le navigateur va tenter une nouvelle connexion 3 secondes apres que vous ayez fermé cette alerte. Dans le doute, vous pouvez vérifier que le plug-in quicktime est correctement installé et autorisé.',
		'mes_quicktime_not_up_to_date'	: '<h4>Votre version de QuickTime n\'est pas &agrave; jour</h4><h5>La version attendue est au moins la version : <span id="ow_quicktime_expected_version"></span></h5> <h5>Pour installer une version plus récente de QuickTime <a href="http://www.apple.com/fr/quicktime/download/">téléchargez l\'installeur sur le site d\'Apple (suivez ce lien)</a></h5>',
		'mes_quicktime_not_available'	: '<h4>Vous n\'avez pas QuickTime install&eacute;</h4> <h5>Pour installer QuickTime <a href="http://www.apple.com/fr/quicktime/download/">téléchargez l\'installeur sur le site d\'Apple (suivez ce lien)</a></h5><h5>Si QuickTime est correctement install&eacute; sur votre machine et que ce message apparait quand m&ecirc;me, <a href="mailto:orao@opsomai.com">n\'hésitez pas à nous contacter</a> avec une description de votre configuration (nom et version de votre navigateur, système d\'exploitation et version de Quicktime installée)</h5>',
		'mes_flash_not_available'	: '<h4>Adobe Flash n\'est pas installé ou nécessite une mise à jour</h4> <h5>Pour installer Flash (ou effectuer une mise à jour) <a href="http://www.macromedia.com/go/getflash/">téléchargez l\'installeur sur le site d\'Adobe (suivez ce lien)</a></h5><h5>Si Flash est correctement install&eacute; sur votre machine et que ce message apparait quand m&ecirc;me, <a href="mailto:orao@opsomai.com">n\'hésitez pas à nous contacter</a> avec une description de votre configuration (nom et version de votre navigateur, système d\'exploitation et version de Flash installée)</h5>'
	},
	tooltips_en				: {
		'ow_id_timecode' 				: 'Time Code (HH:mm:ss)',
		'ow_id_timecodeLong' 			: 'Time Code (HH:mm:ss.frame)',
		'ow_id_sound_slider'			: 'Sound volume',
		'ow_id_progress_slider'			: 'Progress bar',
		'ow_id_jog_slider'				: 'Jog Shuttle',
		'ow_bouton_play' 				: 'Play',
		'ow_bouton_pause' 				: 'Pause',
		'ow_bouton_play_pause' 			: 'Play or Pause (switch)',
		'ow_bouton_play_again'			: 'Restart the player',
		'ow_bouton_fast_rewind' 		: 'Fast rewind',
		'ow_bouton_fast_forward' 		: 'Fast forward',
		'ow_bouton_step_rewind'			: 'Back up one image',
		'ow_bouton_step_forward'		: 'Forward by one image',
		'ow_bouton_go_to_beginning'		: 'Go to the beginning',
		'ow_bouton_go_to_end'			: 'Go to the end',
		'ow_bouton_fullscreen_open'		: 'Show full screen',
		'ow_bouton_fullscreen_close'	: 'Exit full screen',
		'ow_bouton_mute_sound' 			: 'Sound off',
		'ow_bouton_max_sound' 			: 'Max the sound',
		'ow_bouton_left_sound'			: 'Get only the left side of the sound'	,
		'ow_bouton_right_sound'			: 'Get only the right side of the sound'	,
		'ow_bouton_logo_player'			: 'OraoWeb : QuickTime + Javascript Player',
		'ow_selection_start_handle'		: 'Extract beginning',
		'ow_selection_end_handle'		: 'Extract end',
		'ow_bouton_help'				: 'Show help screen',

		'mes_help_title'				: 'Help',
		'mes_help'						: '<h4>To create your own extract:</h4><p>- select the beginning of the extract: click on ow_bouton_beg_selection<br>- select the end of the extract: click on ow_bouton_end_selection<br>- key in your title<br>- save your extract: click on ow_bouton_save_selection</p><h4>To create another extract: click on ow_bouton_new_selection</h4><h4>To annotate your extract: click on ow_bouton_annotate_selection</h4><h5>[ return to viewing ]</h5>',
		'mes_copyright_title'			: 'Orao : Quicktime + Javascript Player',
		'mes_copyright'					: 'Orao : QuickTime Player. Ver.'+ OW_OraoWeb_version +' ('+OW_OraoWeb_version_release_date+'). Copyright Opsomai',

		'mes_plugin_not_yet_ready'		: 'It looks like the video player cannot reach the video plug-in. This can be due to a slow computer. It will try again 3s after you close this alert message. Please check that QuickTime plug-in is installed and authorised.',
		'mes_quicktime_not_up_to_date'	: '<h4>Your QuickTime is not up to date</h4><h5>The expected version is at least : <span id="ow_quicktime_expected_version"></span></h5>  <h5>To install a recent version of QuickTime, please <a href="http://www.apple.com/quicktime/download/">visit the Apple web site and follow the procedure.</a><h5>',
		'mes_quicktime_not_available'	: '<h4>QuickTime is not installed on your machine</h4> <h5>To install this tool, please <a href="http://www.apple.com/quicktime/download/">visit the Apple web site and follow the procedure.</a><h5><h5>If QuickTime is indeed intalled on your machine, please <a href="mailto:orao@opsomai.com">send us an email</a> with a description of your configuration (name and version of your web browser and Operating System, version of installed QuickTime)</h5>',
		'mes_flash_not_available'	: '<h4>Adobe Flash is not installed on your machine or is not up to date</h4> <h5>To install, or update, this tool, please<a href="http://www.macromedia.com/go/getflash/">visit the Adobe web site and follow the procedure.</a></h5><h5>If Flash is indeed intalled on your machine, please <a href="mailto:orao@opsomai.com">send us an email</a> with a description of your configuration (name and version of your web browser and Operating System, version of installed Flash)</h5>'
	}
},

/*	Global variables											*/
/****************************************************************/
basic_function_button			: null 	,	// Will host the list of function directly attach to a button
qt_progress_events				: 0		,	// Count the number of qtload event to reduce the number of used one
timecode						: null	,	// function that will return current timecode : this.timecode()
button_to_default_back			: ''	,	// eg : 'ow_bouton_step_forward'. The default icon is set for that button
plugin_status					: '' 	, // status du plug-in
plugin_ID						: '' 	, // ID of the plug-in (read from a received event)
plugin_to_register_events		: null 	, // always the enclosing object

/*	Pointeur vers les timers									*/
/****************************************************************/
timer_position					: null 	,	// pointeur vers timer du controller
timer_stepping					: null	,	// pointeur vers timer du stepping
timer_stepping_second_phase		: 0		,	// count to define the beginning of the second phase
the_stop_the_stepping			: null  ,	// callback function call to stop the stepping
											// added and removed from the document observe list
/*	Flags														*/
/****************************************************************/
context_update_position			: false ,	// Ne pas changer la position/taux de chargement de la video (slider) ...
context_update_chargement		: false ,	//  ... quand le onChange est du a l'idle de la video
update_chargement_called_at_least_once : false , // Update cahrgement should be called at least once , after the plug-in started revceiving update
video_should_be_relaunched		: false , 	// keep start that the video should be relaunch after the use of the jog
reach_the_beginning				: true	,	// video reach the beg. : can not start fast rewinding
reach_the_end					: false ,	// video reach the end  : can not start playing nor fast forwarding
flag_context_program_resize		: true	,	// When the program is resizing the window, one should not listen to "onresize" events
flag_media_stopped_once			: false	,	// set to true as soon as the function StopTheVideo is called
	// used when dealing with an autoplay video that does not want to autostart ! 

events_are_registred			: false	,	// make sure events are eventually properly registered
late_stuff_are_done				: false	,	// when everythin is satbilized
flag_container_size_read_before_first_autofit	: false,	// make sure that the correct container size is memorized before the first autofit
flag_first_FitIntoNewScreen		: true ,	// under IE, for the first FitIntoNewScreen, we call it a second time
flag_should_set_position_when_loading_reach_selection	: false,
/*	Jog Shuttle													*/
/****************************************************************/
jog_slider						: null	, 	// jog slider
jog_sliderLastValue				: 2		,  	// jog slider last value
jog_was_slided					: false	,	// jog was slided ...
jog_was_set						: false ,	// jog was set ...
jog_was_slided_and_set			: false ,	//  ... yes you guessed it right :-)


/*	Global values : parameters not set by the user				*/
/****************************************************************/
duration						: 0		,	// duration of the video : this.theVideo.GetDuration
movie_time_scale				: 1 	,	// QT scale : this.theVideo.GetTimeScale
movie_time						: 0 	,	// Current time : this.theVideo.GetTime
time_last_position_update		: 0 	,	// Used with min_time_between_position_update to limit the javascript activity
min_time_between_position_update: 40	, 	// 40ms = 1000 ms / 25 frame
last_time_window_was_resized	: 0		,	// Same as above, but with min_time_between_window_update
min_time_between_window_update	: 300	,	// ms
last_available_width			: 0 	,	// Used to avoid non necessary resizes
last_available_height			: 0 	,	// 			//
minimum_available_width			: 0 	,	// If the available witdth is smaller, then window size is reset by the software
minimum_available_height		: 0 	,	// 			//

chargement						: 0 	, 	// etat du chargement de la video
chargementDone 					: false	, 	// chargement_done
position						: 0 	, 	// last set position of the slider
new_position					: 0 	, 	// next position of the slider
rate							: 0 	, 	// playing Rate
						// declared outside the function where it is used only to 
						// alleviate garbage collection issue

	// Management of the rewind mode when QT lt last_QT_version_for_manual_rewind
last_QT_version_for_manual_rewind	: '19.5' , // Can be modified to decide if one should rewind manually or through QT
									// Right now it is visible that we do not trust QuickTime for a fast rewind
									// ... except when we are dealing with sound 
									// 	N.B.: A string is expected here, to be compatible with for instance 7.3.2
manual_rewind_timer				: null ,	// update of the position when rewind and QTvers lt last_QT_version_for_manual_rewind
rewind_speed					: 0 	,	// then the speed is memorize in this variable
last_time_for_rewind			: 0 	,	
last_position_for_rewind		: 0 	,
new_time_for_rewind				: 0 	,
new_position_for_rewind			: 0 	,
date_for_rewind					: 0 	,

	// Management of the sound
sound_slider_set_volume_flag	: false ,	// has the sound already been set ?
sound_slider					: null 	,	// the slider object
sound_handle_height				: 10 	,	// used only if sound_handle_variable is true
	// Management of direct interaction with Quicktime
	// When the user interract directly with the quicktime plug-in, without passing trough javascript, it happens that 
	// the update loop is not started. We have to check that time to time
last_sound_value				: 128 	,


// The are still some variables declared at the end of this file : the debug related ones.

/****************************************************************/
/*		Methods Declarations									*/
/*									Methods Declarations		*/
/****************************************************************/

/****************************************************************/
/*		Initialisation Phase									*/
/****************************************************************/

// 	Initialisation of the object
initialize: function(_container, _options) {
	var o, preset;	
	this.theReleaseOfTheJogShuttle 	= 	this.ReleaseOfTheJogShuttle.bind(this);
	this.the_stop_the_stepping		=	this.StopTheStepping.bind(this);
	this.containerName = _container;
	// this.container.update("");
	// this.container.setStyle({position: 'relative'});
	this.copyright = 'Orao : Player QuickTime. Ver.'+ OW_OraoWeb_version +' ('+OW_OraoWeb_version_release_date+'). Copyright Opsomai';

	// Loading of a preset
	if(_options.preset)	{
		if(this[_options.preset])	{
			preset = this[_options.preset];
			for (o in preset) {
				if (preset.hasOwnProperty(o))	{
					this.movie_options[o] = preset[o];
				}
			}
		}
	}
			
	for (o in _options) {
		if (_options.hasOwnProperty(o))	{
			this.movie_options[o] = _options[o];
		}
	}
	
	if (this.movie_options.language == 'fr')	{		
		this.tooltips = this.movie_options.tooltips_fr;
	}	else	{
		this.tooltips = this.movie_options.tooltips_en;
	}
	
	if (this.movie_options.webmasterEmail)	{
		this.tooltips.mes_quicktime_not_available = this.tooltips.mes_quicktime_not_available.gsub(/orao\@opsomai\.com/, this.movie_options.webmasterEmail);
		this.tooltips.mes_quicktime_not_up_to_date = this.tooltips.mes_quicktime_not_up_to_date.gsub(/orao\@opsomai\.com/, this.movie_options.webmasterEmail);
		this.tooltips.mes_flash_not_available = this.tooltips.mes_flash_not_available.gsub(/orao\@opsomai\.com/, this.movie_options.webmasterEmail);
		
	}
			
	if (!this.movie_options.controller_panel_width)	{
		this.movie_options.controller_panel_width = this.movie_options.width;
	}	
	
	if (this.movie_options.free_lateral_width < 0)	{
		this.movie_options.free_lateral_width = this.movie_options.free_lateral_width_in_FS;
	}
								
	// Writing of the help ++++++++++++++++++++++++++++++++++++++++++++++
	if (this.movie_options.config_help	||	this.movie_options.help)		{
		this.AttachConfigHelpPanel();
		return;
	}			
														
	this.container = $(this.containerName);
	if(this.movie_options.quicktimeDetection)	{
		if(this.GetQuicktimeDetector().isQTInstalled() && !this.movie_options.simulateQTnotAvailable)	{
			this.quicktime_version = this.GetQuicktimeDetector().getQTVersion();
			if (this.GetQuicktimeDetector().isQTCompatible(this.movie_options.expectedQTversion, this.quicktime_version))	{
				// Normal case, when QT is available in the right version
				if (Prototype.Browser.IE)	{
					this.ImagePreLoadingForIE();
				}
				this.AttachPlayer();
				this.CheckThePluginIsLoaded.bind(this).delay(5);
			}	else	{	// QT is installed, but not the expected version
				this.container.update('<div id="ow_quicktime_alert">' + this.tooltips.mes_quicktime_not_up_to_date + '</div>');
				// document.writeln('<div id="ow_quicktime_alert">' + this.tooltips.mes_quicktime_not_up_to_date + '</div>');
				$('ow_quicktime_expected_version').update(this.movie_options.expectedQTversion);
				$('ow_quicktime_alert').setStyle({backgroundImage: 'url('+ this.movie_options.imageRootURL+this.movie_options.images.ow_logo_quicktime +')'});
			}
		}	else	{		// QT is not available				
			this.container.update('<div id="ow_quicktime_alert">' + this.tooltips.mes_quicktime_not_available + '</div>');
			// document.writeln('<div id="ow_quicktime_alert">' + this.tooltips.mes_quicktime_not_available + '</div>');
			$('ow_quicktime_alert').setStyle({backgroundImage: 'url('+ this.movie_options.imageRootURL+this.movie_options.images.ow_logo_quicktime +')'});
		}	
	}	else	{  // No QT detection is required
		this.quicktime_version = '7.5';
		if (Prototype.Browser.IE)	{
			this.ImagePreLoadingForIE();
		}
		this.AttachPlayer();
		this.CheckThePluginIsLoaded.bind(this).delay(5);
	}
	
	if(this.movie_options.sound_level) { // Only for the sound display
		this.last_QT_version_for_manual_rewind = '1.0.0';
		this.SayHelloToFlashAfterThisObjectIsCreated.bind(this).delay(1);				
	}
},

SayHelloToFlashAfterThisObjectIsCreated: function()	{
	if (flashObjectIsReadyToBeCalled)	{
		this.flash_movie = this.GetFlashMovie(''+this.movie_options.flash_movie_name);
		this.flash_movie.sayToFlashJavascriptIsReady();
	}	else	{
		// alert('Laissons un peu plus de temps a Flash : '+this.movie_options.flash_movie_name);
		//  a reduire a 1
		this.SayHelloToFlashAfterThisObjectIsCreated.bind(this).delay(1);
	}
},

AttachPlayer: function() {					
	if (this.movie_options.fullscreen) {
		window.moveTo(0,1);
		window.resizeTo(window.screen.availWidth,window.screen.availHeight);
		window.focus();
		window.moveTo(0,1);
		this.movie_options.width = document.viewport.getWidth();
		this.movie_options.height = document.viewport.getHeight() - this.movie_options.controller_panel_height;
	}			

	if (this.movie_options.timecode_with_frame) {
		this.timecode = this.LongTimeCode.bind(this);
		this.tooltips.ow_id_timecode = this.tooltips.ow_id_timecodeLong;
	} else	{
		this.timecode = this.ShortTimeCode.bind(this);
	}

	if (this.movie_options.timecode_lag)	{ 
		this.movie_options.timecode_lag_in_second = this.LongTimeCodeToTimeInSecond(this.movie_options.timecode_lag);
	}

	// if (this.movie_options.images.ow_background_player)	{ 
	// 	this.container.setStyle({backgroundImage: 'url('+this.movie_options.imageRootURL+this.movie_options.images.ow_background_player+')'});
	// }
	
	
	// for IE: remove QuickTime from browser memory
	Event.observe(window, 'unload', function() {
		// alert('About to unload the page');
		this.DetachMovie();
		// alert('About to close the door');
		}.bind(this)
	);

	this.basic_function_button	= {
		'ow_bouton_play'				: this.PlayTheVideo.bind(this),
		'ow_bouton_pause'				: this.StopTheVideo.bind(this),
		'ow_bouton_fast_rewind'			: this.FastRewind.bind(this),
		'ow_bouton_fast_forward'		: this.FastForward.bind(this),
		'ow_bouton_step_rewind'			: this.StartTheStepping.bind(this, -1),
		'ow_bouton_step_forward'		: this.StartTheStepping.bind(this, 1),
		'ow_bouton_mute_sound'			: this.SetSoundVolume.bind(this, 0),				
		'ow_bouton_max_sound'			: this.SetSoundVolume.bind(this, 255),
		'ow_bouton_go_to_beginning'		: this.GoToBegSelection.bind(this),
		'ow_bouton_go_to_end'			: this.GoToEndSelection.bind(this)
	};

	if (this.movie_options.onSoundBalanceCalled) {
		// alert('Added 2 function sound Balance)');
		this.basic_function_button.ow_bouton_left_sound =  this.movie_options.onSoundBalanceCalled.bind(this,-128);
		this.basic_function_button.ow_bouton_right_sound =  this.movie_options.onSoundBalanceCalled.bind(this,127);
	}

	this.AttachMovie();
	
},

LaunchABitLater: function() { 
	if (!this.late_stuff_are_done)	{
		this.container = $(this.containerName);
		this.late_stuff_are_done = true;
		this.player_panel = $('videoplayer');
		this.movie_panel = $('movieplayer');
		this.AttachMovieController();			
		this.AttachOtherPanels();	
		this.RegisterEvents.bind(this).defer();
		// this.RegisterEvents();
		if (this.movie_options.minimum_available_width)	{
			this.minimum_available_width = this.movie_options.minimum_available_width;
		}	else	{
			this.minimum_available_width = document.viewport.getWidth();
		}
		if (this.movie_options.minimum_available_width)	{
			this.minimum_available_height = this.movie_options.minimum_available_height;
		}	else	{
			this.minimum_available_height = document.viewport.getHeight();
		}
		if (this.movie_options.container_width_after_FS)	{
			this.container_width = this.movie_options.container_width_after_FS;
		}	else	{
			this.container_width = this.container.getWidth();
		}
		
		if(window.console) {
				window.console.log("this.container_width : " + this.container_width);
		} 
		
		document.observe('dom:loaded', this.LaunchAfterLoaded.bind(this));	// Danger : ce qui suit n'est pas toujours appelé
								// car il arrive que le dom soit déjà loadé a ce niveau !!!
	}
},

LaunchAfterLoaded: function() {	
	if (this.movie_options.minimum_available_width)	{
		this.minimum_available_width = this.movie_options.minimum_available_width;
	}	else	{
		this.minimum_available_width = document.viewport.getWidth();
	}
	if (this.movie_options.minimum_available_width)	{
		this.minimum_available_height = this.movie_options.minimum_available_height;
	}	else	{
		this.minimum_available_height = document.viewport.getHeight();
	}
	if (this.movie_options.container_width_after_FS)	{
		this.container_width = this.movie_options.container_width_after_FS;
	}	else	{
		this.container_width = this.container.getWidth();
	}
},

AttachMovie: function() {
	var opts, code, hasRightVersion;
	opts = this.movie_options;

	/*if (this.container.getStyle('position') == 'static') {
		this.container.setStyle({position: 'relative'});
	}*/

	// Player and  Movie Panels ======================================================

	// this.player_panel 	= new Element('div', { 'id': 'videoplayer'});
	// this.movie_panel 	= new Element('div', { 'id': 'movieplayer'});
	// this.player_panel.appendChild(this.movie_panel);
	// this.container.appendChild(this.player_panel);

	// document.writeln('<div id="videoplayer">  <div id="movieplayer"> ');
	code = '<div id="videoplayer">  <div id="movieplayer"> ';
	if (opts.sound_level)	{
		code += QT_GenerateOBJECTText_XHTML(
						opts.url, opts.width, 2, '', 
						'autoplay', 		opts.autoplay	, 
						'controller', 		'false'			, 
						'kioskmode', 		'true'			, 
						'showlogo', 		'false'			, 
						'bgcolor', 			opts.movie_background_color			, 
						'align', 			'middle'		,
						'enablejavascript', 'true'			,
						'postdomevents', 	'true'			,
						'target', 			'myself'		,
						'cache', 			'false'			,
						'qtsrcdontusebrowser', 'true'		,
						'type', 			opts.typeMime	,
						'obj#id',			opts.name		,
						'emb#NAME',			opts.name		,
						'emb#id',			opts.name+'emb'	);	
	}	else	{
		code += QT_GenerateOBJECTText_XHTML(
						opts.url, opts.width, opts.height, '', 
						'autoplay', 		opts.autoplay	, 
						'controller', 		'false'			, 
						'kioskmode', 		'true'			, 
						'showlogo', 		'true'			, 
						'bgcolor', 			opts.movie_background_color			, 
						'scale', 			opts.scale		, 
						'align', 			'middle'		,
						'enablejavascript', 'true'			,
						'postdomevents', 	'true'			,
						'target', 			'myself'		,
						'cache', 			'false'			,
						'qtsrcdontusebrowser', 'true'		,
						'type', 			opts.typeMime	,
						'obj#id',			opts.name		,
						'emb#NAME',			opts.name		,
						'emb#id',			opts.name+'emb'	);	
	}
	// alert(code);
	// this.movie_panel.update(code);	
	// this.container.innerHTML=code;
	// document.writeln(code); 
	
	if (opts.sound_level)	{
		if (!AC_FL_RunContent || !DetectFlashVer) {
			alert("Cette page nécessite le fichier AC_RunActiveContent.js.");
		} else {
			hasRightVersion = DetectFlashVer(requiredMajorVersion, requiredMinorVersion, requiredRevision);
			if(hasRightVersion) {  // si nous avons détecté une version acceptable
				// intégrer le clip Flash
				// alert('About to create the flash object : ' + opts.flash_movie_name);
				// document.writeln('<div id="ow_flash_player">');
				code += '<div id="ow_flash_player">';
				code += AC_FL_RunContent(
					'codebase', 'http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,115,0',
					'width', '320',
					'height', '240',
					'src', 'ow_flash/ow_soundLevel',
					'quality', 'high',
					'pluginspage', 'http://www.macromedia.com/go/getflashplayer',
					'align', 'middle',
					'play', 'true',
					'loop', 'true',
					'scale', 'showall',
					'wmode', 'window',
					'devicefont', 'false',
					// 'id', ''+opts.flash_movie_name,
					'id', ''+opts.flash_movie_name,
					'bgcolor', '#ffffff',
					// 'name', ''+opts.flash_movie_name,
					'name', ''+opts.flash_movie_name,
					'menu', 'true',
					'allowScriptAccess','sameDomain',
					'allowFullScreen','false',
					// 'movie', ''+opts.flash_movie_name,
					'movie', ''+opts.flash_movie_name,
					'salign', ''); 
				//end AC code
				code += '</div>';
				// document.writeln('</div>');
				
			} else {  // version Flash trop ancienne ou détection du plug-in impossible
				// alternateContent = 'Flash n\'est pas installé ou nécessite une mise à jour'
				// 	+ 'Ce contenu requiert Adobe Flash Player. '
				// 	+ '<a href=http://www.macromedia.com/go/getflash/>Obtenir Flash</a>';
					// mes_quicktime_not_available
				// this.container.update('<div id="ow_flash_alert">' + this.tooltips.mes_flash_not_available + '</div>');
				code += '<div id="ow_flash_alert">' + this.tooltips.mes_flash_not_available + '</div>';
				// $('ow_flash_alert').setStyle({backgroundImage: 'url('+ this.movie_options.imageRootURL+this.movie_options.images.ow_logo_flash +')'});					
			}
		}
	}
	
	// document.writeln('</div>  </div>');
	code += '</div> </div>';
	try {
		// document.writeln(code);  
		
		$(this.containerName).update(code);
		// document.getElementById('targetcontainer').innerHTML =code;
		this.container = $(this.containerName);
		this.player_panel 	= $('videoplayer');
		this.movie_panel 	= $('movieplayer');
		// MODIF PVK20080916 
		// document.observe('dom:loaded', this.LaunchABitLater.bind(this));
		this.LaunchABitLater();
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug document.writeln().' +
				'\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
	 // alert(code);
	// this.container.update(code);
},

AttachMovieController: function() {
	var opts, imgInBouton, _bouton, img, ow_position_slider_template, position_handle_image, ow_jog_slider_template, jog_handle_image, ow_sound_slider_template, sound_handle_image;
	
	opts = this.movie_options;
	this.controller_panel = new Element('div', { 'id': 'ow_controllerpanel'});
	this.controller_panel.setStyle({	width	: opts.controller_panel_width+'px',	
										height	: opts.controller_panel_height+'px'});
	
	this.controller_panel.update(opts.code_controller);
	this.player_panel.appendChild(this.controller_panel);
	
	if ($('ow_id_timecode'))	{
		if (this.movie_options.timecode_with_frame) {
			$('ow_id_timecode').update('--:--:--:--');
		} else	{
			$('ow_id_timecode').update('--:--:--');
		}			

		$('ow_id_timecode').writeAttribute({		// 'href'	: '#', 
											'alt'	: this.tooltips.ow_id_timecode,
											'title'	: this.tooltips.ow_id_timecode	});
	}
	
	//Debug
	if(opts.debug_mode)	{
// 				alert('Mode Debug On');
		this.debug_panel = new Element('div', { 'id': 'ow_debugArea'});
		this.debug_panel.setStyle({width: opts.width+'px'});
		this.debug_panel.update(this.debug_feedback);			
		this.container.appendChild(this.debug_panel);
		
	}

	// All the basic function buttons at once  ++++++++++++++++++++++++++++++++++++++++
	for (_bouton in this.basic_function_button) {
		// alert('About to add ' + _bouton);
			if($(_bouton)) 	{
			$(_bouton).writeAttribute({			// 		'href'	: '#', 
										'alt'	: this.tooltips[_bouton],
										'title'	: this.tooltips[_bouton]	});
			// onclick => onmousedown
			$(_bouton).onmousedown = this.basic_function_button[_bouton];
			imgInBouton = $(_bouton).childElements().find(function(_el) {	return _el.match('img'); });
			if (imgInBouton)	{
				imgInBouton.writeAttribute({	'src'	:  opts.imageRootURL+opts.images[_bouton],
															'class'	:  'ow_buttons'	});
			}
			// alert('Added ' + _bouton);
		}
	}
	
	
	// SoundBalance button : Addition from the basic function set +++++++++++++++++++++++++++++++++++++
	
	if (this.movie_options.sound_balance>0)	{
		imgInBouton = $('ow_bouton_left_sound').childElements().find(function(_el) {	return _el.match('img'); });
		imgInBouton.writeAttribute({	'src'	:  opts.imageRootURL+opts.images.ow_bouton_left_sound_off	});
	}	else if (this.movie_options.sound_balance<0)	{
		imgInBouton = $('ow_bouton_right_sound').childElements().find(function(_el) {	return _el.match('img'); });
		imgInBouton.writeAttribute({	'src'	:  opts.imageRootURL+opts.images.ow_bouton_right_sound_off	});
	}
	
	// Play / Pause button ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
	if($('ow_bouton_play_pause')) 	{
		this.button_play_pause_exist = true;
		$('ow_bouton_play_pause').writeAttribute({		//	'href'	: '#', 
											'alt'	: this.tooltips.ow_bouton_play_pause,
											'title'	: this.tooltips.ow_bouton_play_pause	});
		$('ow_bouton_play_pause').onclick = this.ToggleTheVideo.bind(this);
		if(opts.autoplay)	{
			$$('#ow_bouton_play_pause img')[0].writeAttribute({	'src'	:  opts.imageRootURL+opts.images.ow_bouton_pause,
																'class'	:  'ow_buttons'	});
		}	else	{
			$$('#ow_bouton_play_pause img')[0].writeAttribute({	'src'	:  opts.imageRootURL+opts.images.ow_bouton_play,
																'class'	:  'ow_buttons'	});	
		}
		
	}			
	
	// Open/Close Full Screen button ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
	  if($('ow_bouton_fullscreen'))	{
	
		if (opts.fullscreen) {	// Close the FullScreen
			$('ow_bouton_fullscreen').writeAttribute({
				// 'href'	: '#', 
				'alt'	: this.tooltips.ow_bouton_fullscreen_close,
				'title'	: this.tooltips.ow_bouton_fullscreen_close	});
			$('ow_bouton_fullscreen').onclick =  function(){window.close();}; 
			$$('#ow_bouton_fullscreen img')[0].writeAttribute({	'src'	:  opts.imageRootURL+opts.images.ow_bouton_fullscreen_close,
																'class'	:  'ow_buttons'	});
		}	else	{	// open the Full Screen
			$('ow_bouton_fullscreen').writeAttribute({
				// 'href'	: '#', 
				'alt'	: this.tooltips.ow_bouton_fullscreen_open,
				'title'	: this.tooltips.ow_bouton_fullscreen_open	});
				if (opts.popUpFullscreen)	{
					$('ow_bouton_fullscreen').onclick = this.OpenFullScreen.bind(this);
				}	else	{
					$('ow_bouton_fullscreen').onclick = this.SwitchToFullScreen.bind(this);
				}
			$$('#ow_bouton_fullscreen img')[0].writeAttribute({	'src'	:  opts.imageRootURL+opts.images.ow_bouton_fullscreen_open,
																'class'	:  'ow_buttons'	});
		}
	}			

	// Help button ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
	if($('ow_bouton_help')) 	{
		$('ow_bouton_help').writeAttribute({		//	'href'	: '#', 
											'alt'	: this.tooltips.ow_bouton_help,
											'title'	: this.tooltips.ow_bouton_help	});
		$$('#ow_bouton_help img')[0].writeAttribute({	'src'	:  opts.imageRootURL+opts.images.ow_bouton_help,
														'class'	:  'ow_buttons'	});
		$('ow_bouton_help').observe('click', this.ShowHelpPanel.bindAsEventListener(this)) ;
		// $('ow_bouton_help').onclick = this.DetachMovie.bind(this);
		
		// alert('mes help : \n'+this.tooltips.mes_help);
		// User Help Panel ++++++++++++++++++++++++++++++++++++++
		for (img in opts.images) {
			if (opts.images.hasOwnProperty(img))	{
				this.tooltips.mes_help = this.tooltips.mes_help.sub(img,
						function(match) { 
							// alert(match[0] + '\n' + opts.images[match[0]] );
							return '<img src="'+ 
											opts.imageRootURL+opts.images[match[0]] +	'">'; 
						}
				);
			}
		}				
		
		this.help_panel = new Element('div', { 'id'	: 'ow_id_code_panel_help'	, 
											'style'	: 'display: none;'			,
											'class' : 'ow_hiddenBelow'			});
		this.help_panel.update(opts.code_panel_help);
		this.container.appendChild(this.help_panel);
		if (opts.help_panel_target)	{
			$(opts.help_panel_target).appendChild(this.help_panel);
		}	else	{
			this.container.appendChild(this.help_panel);
		}
		$('ow_help_panel_title').update(this.tooltips.mes_help_title);
		$('ow_help_panel_content').update(this.tooltips.mes_help);				

	}			

	// Logo button ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
	
	if($('ow_bouton_logo_player')) 	{
		$('ow_bouton_logo_player').writeAttribute({		//	'href'	: '#', 
											'alt'	: this.copyright,
											'title'	: this.copyright	});
		$$('#ow_bouton_logo_player img')[0].writeAttribute({	'src'	:  opts.imageRootURL+opts.images.ow_bouton_logo_player,
																'class'	:  'ow_buttons'	});
		}			

	// Position Slider ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 
	if($('ow_id_progress_slider'))	{
		ow_position_slider_template = '	<div id="ow_navigation-wrap1">   '	+
	'		<div id="ow_navigation-wrap2">						 '	+
	'			<div id="ow_navigation-track-start"> </div>		 '	+
	'			<div id="ow_navigation-slider">					 '	+
	'				<div id="ow_navigation-position-handle" style="cursor:col-resize;"> </div>  '	+
	'				<div id="ow_navigation-chargement-handle"></div>	 '	+
	'				<div id="ow_navigation-track-end"></div>	 '	+
	'			</div> <!-- End ow_navigation-slider -->		 '	+
	'		</div> <!-- End ow_navigation-wrap2 -->				 '	+
	'		<div id="ow_navigation_selected_extract"></div>  '	+
	'		<div id="ow_navigation_selected_target"></div>  '	+
	'		</div> <!-- End ow_navigation-wrap1 -->';
		$('ow_id_progress_slider').update(ow_position_slider_template);
		$('ow_navigation-chargement-handle').writeAttribute({
			'alt'	: this.copyright,
			'title'	: this.copyright	});
		$('ow_navigation-track-end').writeAttribute({
			'alt'	: this.copyright,
			'title'	: this.copyright	});
		if(opts.images.ow_image_position_slider)	{
			$('ow_navigation-position-handle').update('');
			position_handle_image = new Element('img', {	'id'	: 'ow_position_handle_image',
															'src'	: opts.imageRootURL+opts.images.ow_image_position_slider});
			$('ow_navigation-position-handle').appendChild(position_handle_image);					
		}
		if(opts.images.ow_background_position_slider)	{
			$('ow_navigation-slider').setStyle({backgroundImage: 'url('+ opts.imageRootURL+opts.images.ow_background_position_slider +')'});
		}
		
		$('ow_navigation-wrap1').setStyle({ width:opts.position_slider_width+'px' });
		$('ow_navigation-wrap2').setStyle({ width:opts.position_slider_width+'px' });
		$('ow_navigation-slider').setStyle({ width:opts.position_slider_width+'px' });
		$('ow_id_progress_slider').writeAttribute({		//	'href'	: '#', 
											'alt'	: this.tooltips.ow_id_progress_slider,
											'title'	: this.tooltips.ow_id_progress_slider	});
		$('ow_navigation_selected_extract').setStyle({ 	width:opts.position_slider_width+'px',
		 												visibility:'hidden' });
		$('ow_navigation_selected_target').setStyle({ 	width:opts.position_slider_width+'px',																 	
														visibility:'hidden' });
		
		this.selectionEventHandler = this.SelectionReceiveAClick.bindAsEventListener(this);
		}		
		
	// Jog Shuttle Slider ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
	if($('ow_id_jog_slider'))	{
		ow_jog_slider_template ='<div id="ow_jog-slider">	<div id="ow_jog-handle"> </div>	</div>';
		$('ow_id_jog_slider').update(ow_jog_slider_template);
		if(opts.images.ow_background_jog_slider)	{
			$('ow_jog-slider').setStyle({backgroundImage: 'url('+ opts.imageRootURL+opts.images.ow_background_jog_slider +')'});
		}
		if(opts.images.ow_image_jog_slider)	{
			$('ow_jog-handle').update('');
			jog_handle_image = new Element('img', {	'id'	: 'ow_jog_handle_image',
															'src'	: opts.imageRootURL+opts.images.ow_image_jog_slider});
			$('ow_jog-handle').appendChild(jog_handle_image);					
		}
		$('ow_jog-slider').setStyle({ width:opts.position_slider_width+'px' });
		$('ow_id_jog_slider').writeAttribute({		//	'href'	: '#', 
											'alt'	: this.tooltips.ow_id_jog_slider,
											'title'	: this.tooltips.ow_id_jog_slider	});				
	}



	// Sound Slider ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
	if($('ow_id_sound_slider'))	{
		ow_sound_slider_template ='<div id="ow_sound-slider">	<div id="ow_sound-handle"></div>	</div>';
		$('ow_id_sound_slider').update(ow_sound_slider_template);
		$('ow_sound-slider').setStyle({backgroundImage: 'url('+ opts.imageRootURL+opts.images.ow_background_sound_slider +')'});
		if(opts.images.ow_image_sound_slider)	{
			$('ow_sound-handle').update('');
			sound_handle_image = new Element('img', {	'id'	: 'ow_sound_handle_image',
															'src'	: opts.imageRootURL+opts.images.ow_image_sound_slider});
			$('ow_sound-handle').appendChild(sound_handle_image);					
		}
		if(opts.sound_handle_variable)	{
			this.sound_handle_height = 1+Math.round((127+15)*(this.movie_options.sound_slider_height-1)/270);
			$('ow_sound-handle').setStyle({ top		: (opts.sound_slider_height-this.sound_handle_height)+'px',	
											height	: this.sound_handle_height+'px' });
		}	else	{
			$('ow_sound-handle').setStyle({ top		: '0px',	
											height	: opts.sound_slider_height+'px' });
		}
		$('ow_id_sound_slider').writeAttribute({		// 	'href'	: '#', 
											'alt'	: this.tooltips.ow_id_sound_slider,
											'title'	: this.tooltips.ow_id_sound_slider	});				
	}
},

AttachOtherPanels: function() {
	var opts = this.movie_options;
	
	// End of Movie Panel ===========================================================
	if(!opts.doNothingOnMovieFinished)	{	// Add End of movie panel only when it will be used
		this.end_movie_panel = new Element('div', { 'id'	: 'ow_id_end_restart_video'	, 
													'style'	: 'display: none;'			,
													'class' : 'ow_hiddenBelow'				});
		if (opts.fullscreen) {
			this.end_movie_panel.update(opts.code_panel_end_FS);
		}	else	{
			this.end_movie_panel.update(opts.code_panel_end);
		}
		this.container.appendChild(this.end_movie_panel);

		// Play Again button ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
		if($('ow_bouton_play_again')) 	{
			$('ow_bouton_play_again').writeAttribute({
				// 'href'	: '#', 
				'alt'	: this.tooltips.ow_bouton_play_again,
				'title'	: this.tooltips.ow_bouton_play_again	
			});
			$('ow_bouton_play_again').onclick = this.LetTheVideoBeVisibleAgain.bind(this);
			$$('#ow_bouton_play_again img')[0].writeAttribute('src',  opts.imageRootURL+opts.images.ow_bouton_play_again);
		}
		// Play again ... End Image
		if($('ow_image_end_restart_video')) 	{
			$('ow_image_end_restart_video').writeAttribute({
				// 'href'	: '#', 
				'alt'	: this.tooltips.ow_bouton_play_again,
				'title'	: this.tooltips.ow_bouton_play_again
			});
			$('ow_image_end_restart_video').onclick = this.LetTheVideoBeVisibleAgain.bind(this);
			$$('#ow_image_end_restart_video img')[0].writeAttribute({
				'src':  opts.urlOfEndImage,
				'width'	: opts.width,
				'height': opts.height,
				'border': 0
			});
		}				
	}	// End of End of Movie Panel =============
	
	
	// Close FS  button ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
	if($('ow_bouton_fullscreen_end')) 	{
		$('ow_bouton_fullscreen_end').writeAttribute({
			// 'href'	: '#', 
			'alt'	: this.tooltips.ow_bouton_fullscreen_close,
			'title'	: this.tooltips.ow_bouton_fullscreen_close	
		});
		$('ow_bouton_fullscreen_end').onclick = function(){window.close();};
		$$('#ow_bouton_fullscreen_end img')[0].writeAttribute('src',  opts.imageRootURL+opts.images.ow_bouton_fullscreen_close);
	}
	
	// Movie-went-to-fullscreen-in-a-different-window Panel ===========================================================			
	if ( (! opts.fullscreen) && opts.popUpFullscreen ){	// we are not in full screen, AND
		 													// we will pop up a new window when going in FS
		this.end_fullscreen_movie_panel = new Element('div', { 'id'	: 'ow_id_wentFS_restart_video'	, 
													'style'	: 'display: none;'			,
													'class' : 'ow_hiddenBelow'				});
		this.end_fullscreen_movie_panel.update(opts.code_end_FS_movie_panel);
		this.container.appendChild(this.end_fullscreen_movie_panel);

		// Play Again button ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
		if($('ow_bouton_play_again_afterFS')) 	{
			$('ow_bouton_play_again_afterFS').writeAttribute({
				// 'href'	: '#', 
				'alt'	: this.tooltips.ow_bouton_play_again,
				'title'	: this.tooltips.ow_bouton_play_again	
			});
			$('ow_bouton_play_again_afterFS').onclick = function(){window.location.reload();};
			$$('#ow_bouton_play_again_afterFS img')[0].writeAttribute('src',  opts.imageRootURL+opts.images.ow_bouton_play_again);
		}
		// Play again ... End Image
		if($('ow_image_wentFS_restart_video')) 	{
			$('ow_image_wentFS_restart_video').writeAttribute({
				// 'href'	: '#', 
				'alt'	: this.tooltips.ow_bouton_play_again,
				'title'	: this.tooltips.ow_bouton_play_again
			});
			$('ow_image_wentFS_restart_video').onclick = function(){window.location.reload();};
			$$('#ow_image_wentFS_restart_video img')[0].writeAttribute({
				'src':  opts.urlOfReplacementImage,
				'width'	: opts.width,
				'height': opts.height,
				'border': 0
			});
		}
	}
},

CreateSliders		 : function()	{

	//  =======================================  Selection Slider			
	this.position_slider = new Control.Slider(
		['ow_navigation-position-handle','ow_navigation-chargement-handle'],'ow_navigation-slider',{
			range		: $R(0,1000),
			sliderValue	: [0,1000],
			startSpan	: 'ow_navigation-track-start',
			endSpan		: 'ow_navigation-track-end',
			restricted	: true,
			// alignX		: [-2, 0], 
			alignY		: -5,
			
			onSlide:function(v){							
				if  (this.rewind_speed<0)	{
					this.manual_rewind_timer.stop();
					this.theVideo.Stop();
					if (this.button_play_pause_exist)	{ 
						$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images.ow_bouton_play);
					}
					this.rewind_speed = 0;
				}

				try {
					if  (this.theVideo.GetRate() != 0) 	{
						this.theVideo.Stop();
						if (this.button_play_pause_exist)	{ 
							$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images.ow_bouton_play);
						}
						this.video_should_be_relaunched = true;
					}
				}
				catch (err) { 
					// Pierre1
					if (this.movie_options.debug_mode2)	{
						alert('Ref: Bug CreateSliders this.theVideo.GetRate().'
							+ '\nName: ' + err.name + '\nMessage: ' + err.message);
					}
				}

				if ( ! ( this.context_update_position || this.context_update_chargement))	{
					this.GoToPercent(v[0]/10);
				}	
			}.bind(this),
			onChange:function(v){
				if ( ! ( this.context_update_position || this.context_update_chargement)) {
					// dans le cadre d'un deplacement manuel du slider

					this.position = v[0];
					if (this.position == 0)	{
						this.reach_the_beginning = true;
						this.reach_the_end = false;
					} else if (this.position >= 1000)	{
						this.reach_the_beginning = false;
						this.reach_the_end = true;
					} else {
						this.reach_the_beginning = false;
						this.reach_the_end = false;
					}

					if  (this.rewind_speed<0)	{
						this.manual_rewind_timer.stop();
						this.theVideo.Stop();
						if (this.button_play_pause_exist)	{ 
							$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images.ow_bouton_play);
						}
						this.rewind_speed = 0;
					}

					try {
						if  (this.theVideo.GetRate() != 0) 	{
							this.theVideo.Stop();
							if (this.button_play_pause_exist)	{ 
								$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images.ow_bouton_play);
							}
							this.video_should_be_relaunched = true;
						}	else	{
							//when not playing, one can get out of the selection
							if(this.flag_sub_selection_set) { 	// une selection est  en cours
								this.flag_sub_selection_QT_tmp_unset = true;
								this.theVideo.SetStartTime(this.tcIN_in_QTTime);
								this.theVideo.SetEndTime(this.theVideo.GetMaxTimeLoaded());
							}
							
						}
					}
					catch (err) { 
						// Pierre2
						if (this.movie_options.debug_mode2)	{
							alert('Ref: Bug Pierre2 : this.theVideo.GetRate().'
								+ '\nName: ' + err.name + '\nMessage: ' + err.message);
						}
					}
					this.GoToPercent(v[0]/10);

					if (this.video_should_be_relaunched && !this.reach_the_end)	{
						this.resetJogleIfNecessary();
						this.theVideo.Play();
						this.video_should_be_relaunched = false;
					}

					// Cas ou l'on touche au slider de chargement
					// (cela n'est pas censé arriver, mais pourtant...)

					try {
						if ((v[1] != 1000) && this.chargement_done) {
							if (this.duration != 0)	{
								this.chargement = Math.round(this.theVideo.GetMaxTimeLoaded()/this.duration * 1000);
								if (this.chargement>950)	{
									this.chargement = 1000;
								}

								if ( !this.context_update_chargement)	{
									this.context_update_chargement=true;
									this.position_slider.setValue(this.chargement, 1);

									if ( !this.context_update_position)	{
										this.context_update_position=true;
										this.position_slider.setValue(this.position, 0);	
										this.context_update_position=false;
									}						
									this.context_update_chargement=false;	
								}						
							}	
						}
					}
					catch (err2) { 
						// Pierre3
						if (this.movie_options.debug_mode2)	{
							alert('Ref: Bug : this.theVideo.GetMaxTimeLoaded().'
								+ '\nName: ' + err2.name + '\nMessage: ' + err2.message);
						}
					}
					this.FocusToTheVideo();
				}						
			}.bind(this)
		}
	);




	//  =======================================  Sound Slider
	if($('ow_id_sound_slider'))	{
		this.sound_slider = new Control.Slider(
			'ow_sound-handle', 'ow_sound-slider',{
				range:$R(0,255),
				sliderValue:128,
				onSlide:function(v){
					this.sound_slider_set_volume_flag=true;
					this.last_sound_value = Math.round(v);
					this.theVideo.SetVolume(this.last_sound_value);
					this.sound_handle_height = 1+Math.round((this.last_sound_value+15)*(this.movie_options.sound_slider_height-1)/270);
					if(this.movie_options.sound_handle_variable)	{
						$('ow_sound-handle').setStyle({ top		: (this.movie_options.sound_slider_height - this.sound_handle_height)+'px',	
														height	: this.sound_handle_height+'px' });
					}
				
				}.bind(this),
				onChange:function(v){
					this.sound_slider_set_volume_flag=true;
					this.last_sound_value = Math.round(v);
					this.theVideo.SetVolume(this.last_sound_value);
					this.sound_handle_height = 1+Math.round((this.last_sound_value+15)*(this.movie_options.sound_slider_height-1)/270);
					if(this.movie_options.sound_handle_variable)	{
						$('ow_sound-handle').setStyle({ top		: (this.movie_options.sound_slider_height - this.sound_handle_height)+'px',	
														height	: this.sound_handle_height+'px' });
					}
				}.bind(this)
			}
		);
	}
	
	//  =======================================  Jog Shuttle Slider 
	if($('ow_id_jog_slider'))	{
		this.jog_slider = new Control.Slider(
			'ow_jog-handle', 'ow_jog-slider',{
				range:$R(0,4),
				sliderValue:2,
				onSlide:function(v){
					this.jog_sliderLastValue = v;
					var value = (v-2);
					if (v < 0.5)	{		// entre -2 et -1.5
						value = 16 * value + 22;  	// -2 => -10 et -1.5 => -2
					}	else if (v<1)	{	// entre -1.5 et -1
						value = 2 * value + 1;		
					}	else if (v<=3) 	{	
						//	(entre -1 et 1 on reste en identique)
					}	else if (v<3.5)	{	// entre 1 et 1.5  
						value = 2 * value -1;
					}	else 	{	// entre 1.5 et 2
						value = 16 * value -22;		// 1.5 => 2 et 2 => 10;
					}	
					if ( (this.reach_the_end && (value > 0)) || (this.reach_the_beginning && (value < 0)) )	{
						if (this.GetQuicktimeDetector().isQTCompatible(this.quicktime_version, this.last_QT_version_for_manual_rewind ))	{
								// When the current version of Quicktime is not powerfull enough to do normal rewind, switch to manual
							if(this.manual_rewind_timer)	{
								this.manual_rewind_timer.stop();
							}									
							this.rewind_speed = 0;
						}
						this.theVideo.Stop();
						this.jog_was_slided = true;
					}	else	{
						if (this.reach_the_end || this.reach_the_beginning)	{
							this.reach_the_end = false;
							this.reach_the_beginning = false;
							// this.theVideo.Start();
						}
						if (	this.GetQuicktimeDetector().isQTCompatible(this.quicktime_version, this.last_QT_version_for_manual_rewind) 
							&& 	((this.rewind_speed<0) || (value<0))	) 	{
							if ((this.rewind_speed<0) && (value<0))	{
								this.rewind_speed = value;
							}	else if (value >=0)	{	// On vient juste de passer de v<0 a v >0 : on passe en mode normal
								this.manual_rewind_timer.stop();
								this.rewind_speed = 0;
								// lanceVideoAvecTimer();
								this.theVideo.SetRate(value);
							}	else	{	// On passe d'un mode normal (this.rewind_speed == 0) en mode saut en arriere (value <0)
								try {
									this.rewind_speed = value;
									this.theVideo.Stop();
									this.date_for_rewind = new Date();
									this.last_time_for_rewind = this.date_for_rewind.getTime();
									this.last_position_for_rewind = this.theVideo.GetTime();
									if (this.manual_rewind_timer)	{
										this.manual_rewind_timer.start();
									}	else	{
										this.manual_rewind_timer = new PeriodicalExecuter( this.UpdatePosWhenRewind.bind(this), 0.099);
									}			
								}
								catch (err) { 
									// Pierre4
									if (this.movie_options.debug_mode2)	{
										alert('Ref: Bug JogShuttle : this.theVideo.GetTime().'
											+ '\nName: ' + err.name + '\nMessage: ' + err.message);
									}
								}
							}			
						}	else	{
							this.theVideo.SetRate(value);
						}
							
						if($('ow_id_jog_value'))	{
							$('ow_id_jog_value').update('x '+Math.round(value*10) / 10);
						}
						this.jog_was_slided = true;
						this.jog_was_slided_and_set = false;
						this.jog_was_set = false;		// a la fin du slide, on va eteindre le jogle
						// donc plus besoin de suivre son etat						
					}
				}.bind(this),
				onChange:function(v){
					this.jog_sliderLastValue = v;
					var value = (v-2);
					if (v < 0.5)	{		// entre -2 et -1.5
						value = 16 * value + 22;  	// -2 => -10 et -1.5 => -2
					}	else if (v<1)	{	// entre -1.5 et -1
						value = 2 * value + 1;		
					}	else if (v<=3) 	{	
						//	(entre -1 et 1 on reste en identique)
					}	else if (v<3.5)	{	// entre 1 et 1.5  
						value = 2 * value -1;
					}	else 	{	// entre 1.5 et 2
						value = 16 * value -22;		// 1.5 => 2 et 2 => 10;
					}	
					if (	(this.reach_the_end && (value>0)) 
						|| 	(this.reach_the_beginning && (value<0)) 	)	{
							// ||	(!this.movie_options.advance_jog_shuttle)
						this.jog_was_slided = true;
						// then the next test will reset everything to 0 : same behaviour than at the end of a slide
					}
					if (this.jog_was_slided)	{ // fin d'une utilisation par slide : retour a zero
						if (this.GetQuicktimeDetector().isQTCompatible(this.quicktime_version, this.last_QT_version_for_manual_rewind ))	{
								// When the current version of Quicktime is not powerfull enough to do normal rewind, switch to manual
							if(this.manual_rewind_timer)	{
								this.manual_rewind_timer.stop();
							}								
							this.rewind_speed = 0;	
						}
						this.StopTheVideo();
						this.jog_was_slided = false;
						this.jog_was_slided_and_set = true;
						this.jog_slider.setValue(2);
						
						if($('ow_id_jog_value'))	{
							$('ow_id_jog_value').update(' ');
						}
						
					} else if (!this.jog_was_slided_and_set)	{ // on ne vient pas d\'un reset apres un slide, donc c\'est un set initial
												// en debut de slide, ou sans slide
						this.ResetTheSelectionIfNeeded();
						if (	this.GetQuicktimeDetector().isQTCompatible(this.quicktime_version, this.last_QT_version_for_manual_rewind ) 
							&&	(this.rewind_speed<0)	)	{
							this.manual_rewind_timer.stop();
							this.rewind_speed = 0;	
						}
						if (	this.GetQuicktimeDetector().isQTCompatible(this.quicktime_version, this.last_QT_version_for_manual_rewind) 
							&&	(value<0)	)	{
							try {
								this.rewind_speed = value;
								this.theVideo.Stop();
								this.date_for_rewind = new Date();
								this.last_time_for_rewind = this.date_for_rewind.getTime();
								this.last_position_for_rewind = this.theVideo.GetTime();
								if (this.manual_rewind_timer)	{
									this.manual_rewind_timer.start();
								}	else	{
									this.manual_rewind_timer = new PeriodicalExecuter( this.UpdatePosWhenRewind.bind(this), 0.099);
								}
								if (this.button_play_pause_exist)	{ 
									$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images.ow_bouton_pause);
								}
							}
							catch (err) { 
								// Pierre6
								if (this.movie_options.debug_mode2)	{
									alert('Ref: Bug onChange : this.theVideo.Stop().'
										+ '\nName: ' + err.name + '\nMessage: ' + err.message);
								}
							}
							
						}	else	{
							this.theVideo.SetRate(value);
						}
						if($('ow_id_jog_value'))	{
							if (value) {
								$('ow_id_jog_value').update('x '+Math.round(value*10) / 10);
							}	else	{
								$('ow_id_jog_value').update(' ');
							}
							
						}		
						if 	(!this.movie_options.advance_jog_shuttle)	{
							document.observe('mouseup', this.theReleaseOfTheJogShuttle);							
						}
						this.jog_was_set = true;  // Si on ne passe pas par un slide, il va falloir faire qqchose (reinit le joggle)
					}	else	{			// on reviens ici apres avoir valide un fin de slide
						// donc on remet le flag a false
						// pour setter en direct : this.jog_was_slided_and_set =true et this.jog_slider.setValue(2);
						this.jog_was_slided_and_set = false;
					}
				}.bind(this)
			}
		);
	}	
},


RegisterEvents:	function() {

	this.plugin_to_register_events = document.getElementById(this.movie_options.name);
	if ( null === this.plugin_to_register_events )	{
		this.plugin_to_register_events = document.getElementById(this.movie_options.name+'emb');
		if ( null === this.plugin_to_register_events )	{               
			alert("Bug when trying to get a pointer to the encapsulating object. Please contact pascal.vuylsteker@opsomai.com ");
			this.events_are_registred = false;
			return;
		}
	}	
	
	if (this.movie_options.automaticallyAdjustSize)	{
		Event.observe(window,'resize', 	this.AutomaticFitIntoNewScreen.bind(this));
	}
	
	this.flag_context_program_resize = false;

	this.AddListener('qt_begin',			this.IsPluginReady.bindAsEventListener(this, null), false);
	this.AddListener('qt_abort',			this.OnEvent.bindAsEventListener(this), false);
	this.AddListener('qt_canplay',			this.OnEvent.bindAsEventListener(this), false);
	this.AddListener('qt_canplaythrough',	this.OnEvent.bindAsEventListener(this), false);
	this.AddListener('qt_durationchange',	this.OnEvent.bindAsEventListener(this), false);
	this.AddListener('qt_ended',			this.OnEvent.bindAsEventListener(this), false);
	this.AddListener('qt_error',			this.CheckThePluginIsLoaded.bindAsEventListener(this), false);
	this.AddListener('qt_load',				this.OnEvent.bindAsEventListener(this), false);
	this.AddListener('qt_loadedfirstframe',	this.OnEvent.bindAsEventListener(this), false);
	this.AddListener('qt_loadedmetadata',	this.OnEvent.bindAsEventListener(this), false);
	this.AddListener('qt_pause',			this.StopTimerPosition.bindAsEventListener(this), false);
	this.AddListener('qt_play',				this.StartTimerPosition.bindAsEventListener(this), false);
	this.AddListener('qt_progress',			this.OnEvent.bindAsEventListener(this), false);
	this.AddListener('qt_stalled',			this.OnEvent.bindAsEventListener(this), false);
	this.AddListener('qt_timechanged',		this.UpdatePosition.bindAsEventListener(this), false);
	this.AddListener('qt_volumechange',		this.SoundChangedFromQT.bindAsEventListener(this), false);            
	this.AddListener('qt_waiting',			this.OnEvent.bindAsEventListener(this), false);    


	this.events_are_registred = true;
	// alert("Events are listened to");	

	if(!this.IsPluginReady(null))	{
		this.CheckAgainIsPluginReady.bind(this).delay(6);
	}
},


CheckAgainIsPluginReady: function	()	{
	if(!this.IsPluginReady(null))	{
		this.CheckAgainIsPluginReady.bind(this).delay(6);
	}
},

AddListener:	function(_event, _function, _captures) {

	$(this.plugin_to_register_events).observe(_event, _function);

	// if ( document.addEventListener )
	// 	this.plugin_to_register_events.addEventListener(_event, _function, _captures);
	// else  if ( document.attachEvent )
	// 	this.plugin_to_register_events.attachEvent('on' + _event, _function); // IE requires this form
	// else
	// 	this.plugin_to_register_events["on" + type] = func;
},


IsPluginReady: function(_event)	{
	if (this.theVideo != null)	{
		return(true);	// The reference is already known
	}	else 	{
		try {
			this.theVideo = document.movie1;
			this.plugin_status = '';
			this.plugin_status = this.theVideo.GetPluginStatus();

			if ( ! ( (this.plugin_status == 'Loading')	|| (this.plugin_status == 'Playable')	|| (this.plugin_status == 'Complete') ))	{
				this.theVideo = null;
				return(false);
			}	else	{
				// if(this.movie_options.debug_mode) $('debug1').update('Plugin is ready');
				if ((!_event) &&(!this.OnEvent(null)))	{
					this.SelfSendPseudoEventAgain.bind(this).delay(4);
				}
				if (this.movie_options.sound_level)	{
					// petit ajustement pour INA CSS idendique (video oou radio)
					// pas tres propre ... mais bon
					$('ow_bouton_help').setStyle({ marginRight		: '60px'});
					$('movie1').setStyle({ 	left	: '0px',
											width	: '32px'});
					// $('movie1').setStyle({ 	position	: 'absolute',
					// 						left		: '0px'});
					// $('movie1').setStyle({ 	position	: 'absolute',
					// 						zIndex		: '-1'});
					// margin-right: 60px;
				}
				return(true);
			}
		}
		catch(err)	{
			// txt="The plug-in was not ready yet.\n";
			// txt+="Error description: " + err.description + "\n";
			//	alert(txt);
			// if (this.movie_options.debug_mode) $('debug1').update('updateChargementError '+ this.debug1++ +txt);
			if (this.movie_options.debug_mode2)	{
				alert('Ref: IsPluginReady'	+ '\nName: ' + err.name + '\nMessage: ' + err.message);
			}
			this.theVideo = null;
			return(false);
		}
	}
},


SelfSendPseudoEventAgain: function()	{
	if (!this.OnEvent(null))	{
		this.SelfSendPseudoEventAgain.bind(this).delay(4);
	}
},


OnEvent: function(_event)	{
	try {
		var opts = this.movie_options;

		if ((this.plugin_status != 'OK') &&	this.IsPluginReady(_event)) {
			try {
				this.plugin_status = this.theVideo.GetPluginStatus();
				this.duration = this.theVideo.GetDuration(); 
				this.movie_time_scale = this.theVideo.GetTimeScale();
			}
			catch (err) { 
				if (this.movie_options.debug_mode2)	{
					alert('Ref: OnEvent_this.theVideo called when plugin is not ready.'
						+ '\nName: ' + err.name + '\nMessage: ' + err.message);
				}
			}

			if (		(this.plugin_status=='Playable' || this.plugin_status=='Complete') 
					&&	(this.duration > 0)
					&& 	(this.movie_time_scale > 0)	)	{	
				// Done the first time a event is sent while the plug-in is ready							

				this.CreateSliders();

				// alert('About to set 0 ( duration / scale / beg / end ): '+ this.duration + ' / ' + this.movie_time_scale + ' / ' + this.QTTimeToLongTimeCode(0)+ ' / ' +	this.QTTimeToLongTimeCode(this.duration));
				// ((_qtTime/this.movie_time_scale)+this.movie_options.timecode_lag_in_second)*25
									
				// Set the timecode as soon as the movie is playable
				if ($('ow_id_timecode'))	{
					// if(opts.debug_mode) $('debug2').update('movie OK PAS  OK '+ this.debugProb++);
					this.movie_time = 0;
					$('ow_id_timecode').update(this.timecode());
				}

				if(opts.timecode_IN)	{
					this.tcIN_in_QTTime = this.LongTimeCodeToQTTime(opts.timecode_IN) - opts.timecode_lag_in_second*this.movie_time_scale;
					this.tcIN_in_QTTime = (this.tcIN_in_QTTime>=0 ? this.tcIN_in_QTTime : 0);
				} 	else	{
					this.tcIN_in_QTTime = 0;
				}
				this.beg_current_selection = this.tcIN_in_QTTime;					

				if(opts.autoplay) 	{	this.reach_the_beginning=false;	}

				this.theVideo.SetVolume(this.last_sound_value);

				if(this.movie_options.sound_level) 	{// update when the media is a sound
					this.timer_position = new PeriodicalExecuter( this.UpdatePosition.bind(this), 0.19);
				}	else	{	// Update when the media is a video 
					this.timer_position = new PeriodicalExecuter( this.UpdatePosition.bind(this), 0.69);
				}
				
								
				this.plugin_status = 'OK';			
				if (opts.onPlayerReady)	{	
					opts.onPlayerReady();
				}					
				if (opts.autoplay)	{
					this.CheckTheAutoplayStatus.bind(this).delay(0.5);
				}
				if (opts.should_select_all)	{
					// alert('About to set 0 ( duration / scale / beg / end ): '+ this.duration + ' / ' + this.movie_time_scale + ' / ' + this.QTTimeToLongTimeCode(0)+ ' / ' +	this.QTTimeToLongTimeCode(this.duration));
					this.SetSelectionAll.bind(this).delay(1);
				}
			}				
		}	
		if (this.plugin_status != 'OK')	{	return(false);	}
		if (!_event) { // false event to simulate the first event to properlly initialize the player when
						//  the loading phase is buggy (Typically with IE)
			this.UpdateChargement(null);
			return(true);	
		}
		// =================== The plug-in is ready to deal with the event
		switch ( _event.type )	{
			case 'qt_play':
			// 	this.timer_position.start();
				break;
			case 'qt_pause':
			// 	this.timer_position.stop();
				break;
			case 'qt_canplay':
				// document.getElementById("movie_duration").innerHTML = plugin.GetDuration();
				// document.getElementById("movie_volume").innerHTML = plugin.GetVolume();
				// document.getElementById("movie_rate").innerHTML = plugin.GetRate();
				break;
			case 'qt_volumechange':
				// document.getElementById("movie_volume").innerHTML = plugin.GetVolume();
				break;
			case 'qt_progress':
				this.qt_progress_events++;
				if (this.qt_progress_events%3 > 0) {
					// $('debug3').update('Skipped qt_progress event '+ this.debug3++);
					break;
				}
			case 'qt_load':
				this.UpdateChargement(_event.type);
				break;
			case 'qt_stalled':
				break;
		}
		// if(this.movie_options.debug_mode) 
		// 	$('debugProb').update('event:'+_event.type+' / qt_progress_events%3: '+ (this.qt_progress_events%3) + ' / '+ this.debugProb++);
	}
	catch (err2) { 
		if (this.movie_options.debug_mode2)	{
			if (_event)	{
				alert('Ref: Bug Pierre14 : OnEvent('+ _event.type + ').'
					+ '\nName: ' + err2.name + '\nMessage: ' + err2.message);
				
			}	else	{
				alert('Ref: Bug Pierre14 : OnEvent(null).'
					+ '\nName: ' + err2.name + '\nMessage: ' + err2.message);
			}
		}
	}
},


CheckTheAutoplayStatus: function()	{
	if (	(!this.flag_media_stopped_once)	&&
			(this.theVideo.GetRate() == 0)	)	{
		this.PlayTheVideo();
		this.CheckTheAutoplayStatus.bind(this).delay(1);
		// alert('Status of this.reach_the_end : '+this.reach_the_end);
	}
},


// Called through event, when the some download progress is detected if the plug-in is OK
UpdateChargement: function(_event_type) {
	try {
		// if(this.movie_options.debug_mode) 
			// $('debugChar').update('UpdateChargement '+ _event_type + ' / ' + this.debugChar++);
		if ((!_event_type)	&& (this.movie_options.automaticallyAdjustSize)) {
			this.AutomaticFitIntoNewScreen();
		}
		
		var opts, status;
		opts = this.movie_options;
		
		this.duration = this.theVideo.GetDuration(); 	
		this.tmpMaxTimeLoaded = this.theVideo.GetMaxTimeLoaded();
		this.chargement = Math.round(this.tmpMaxTimeLoaded/this.duration * 1000);
		
		// update des tcin et tcout en tenant compte de la derniere evaluation de la duree de la video
		if(opts.timecode_OUT)	{
			this.tcOUT_in_QTTime = this.LongTimeCodeToQTTime(opts.timecode_OUT) - 
									opts.timecode_lag_in_second*this.movie_time_scale;
			this.tcOUT_in_QTTime = (this.tcOUT_in_QTTime <= this.duration ? 
									this.tcOUT_in_QTTime : this.duration);
		} 	else	{
			this.tcOUT_in_QTTime = this.duration;
		}
		if(opts.timecode_IN)	{
			this.tcIN_in_QTTime = this.LongTimeCodeToQTTime(opts.timecode_IN) - opts.timecode_lag_in_second*this.movie_time_scale;
			this.tcIN_in_QTTime = (this.tcIN_in_QTTime>=0 ? this.tcIN_in_QTTime : 0);
		} 	else	{
			this.tcIN_in_QTTime = 0;
		}
		
		if(this.tcIN_in_QTTime >= this.tcOUT_in_QTTime)	{
			this.tcOUT_in_QTTime = this.duration;
			if(this.tcIN_in_QTTime >= this.tcOUT_in_QTTime)	{
				this.tcIN_in_QTTime = 0;
				if(this.tcIN_in_QTTime >= this.tcOUT_in_QTTime)	{
					this.tcOUT_in_QTTime = 10;
				}
			}
		}
		
		if(!this.flag_sub_selection_set) {
			this.end_current_selection = this.tcOUT_in_QTTime;
			this.theVideo.SetEndTime(this.end_current_selection);
		}	
		
		status = this.theVideo.GetPluginStatus();
		// if (this.chargement>950)	
		if (this.chargement>=980) 	{
			if ( 	(status =='Complete') ||
					(status =='Playable') )
					{
				this.chargement = 1000;
				this.chargement_done = true;
				// Let's get the latest one, because with some format, QT use an estimation of their value at the beginning of the download
				this.duration = this.theVideo.GetDuration(); 
				this.movie_time_scale = this.theVideo.GetTimeScale();
				if(opts.timecode_OUT)	{
					this.tcOUT_in_QTTime = this.LongTimeCodeToQTTime(opts.timecode_OUT) - opts.timecode_lag_in_second*this.movie_time_scale;
					this.tcOUT_in_QTTime = (this.tcOUT_in_QTTime <= this.duration ? this.tcOUT_in_QTTime : this.duration);
				} 	else	{
					this.tcOUT_in_QTTime = this.duration;
				}
				if(opts.timecode_IN)	{
					this.tcIN_in_QTTime = this.LongTimeCodeToQTTime(opts.timecode_IN) - opts.timecode_lag_in_second*this.movie_time_scale;
					this.tcIN_in_QTTime = (this.tcIN_in_QTTime>=0 ? this.tcIN_in_QTTime : 0);
				} 	else	{
					this.tcIN_in_QTTime = 0;
				}
		
				if(this.tcIN_in_QTTime >= this.tcOUT_in_QTTime)	{
					this.tcOUT_in_QTTime = this.duration;
					if(this.tcIN_in_QTTime >= this.tcOUT_in_QTTime)	{
						this.tcIN_in_QTTime = 0;
						if(this.tcIN_in_QTTime >= this.tcOUT_in_QTTime)	{
							this.tcOUT_in_QTTime = 10;
						}
					}
				}


				if(!this.flag_sub_selection_set) {
					this.end_current_selection = this.tcOUT_in_QTTime;
					this.beg_current_selection = this.tcIN_in_QTTime;

					this.theVideo.SetEndTime(this.end_current_selection);
					this.theVideo.SetStartTime(this.beg_current_selection);
				}	else	{
					this.SetSelection.bind(this).delay(1,this.beg_current_selection_TC, this.end_current_selection_TC);
				}
				if (opts.timecode_with_frame) {
					this.timer_position.changeFrequency(0.19);
				}				
			}	else	{
				alert('pb a traiter : ' + this.theVideo.GetPluginStatus());
			}
		
		} 

		this.context_update_chargement=true;				
		this.position_slider.setValue(this.chargement, 1);

		if ( !this.context_update_position)	{
			this.context_update_position=true;
			this.position_slider.setValue(this.position, 0);	
			this.context_update_position=false;
		}			

		this.context_update_chargement=false;
		
		this.tmpMaxTimeLoaded = this.theVideo.GetMaxTimeLoaded();
		if(this.flag_sub_selection_set)	{		// une selection est deja en cours				
			this.beg_current_selection_vis = (	this.beg_current_selection > this.tmpMaxTimeLoaded ?  
												this.tmpMaxTimeLoaded : this.beg_current_selection );
			this.end_current_selection_vis = (	this.end_current_selection > this.tmpMaxTimeLoaded ?
				 								this.tmpMaxTimeLoaded : this.end_current_selection);

			if (!this.flag_sub_selection_QT_tmp_unset)	{ // pas dans le cas ou l'on drag la position en dehors d'une selection existante
				this.theVideo.SetStartTime(this.beg_current_selection_vis);
				this.theVideo.SetEndTime(this.end_current_selection_vis);					
			}	else	{
				this.theVideo.SetEndTime(this.tmpMaxTimeLoaded);
			}

			this.SetSelectionBar(	1000*this.beg_current_selection_vis/this.duration,
				 					1000*this.end_current_selection_vis/this.duration);	
			
			// version PVK 3.1.4e
			if ( 	(this.flag_should_set_position_when_loading_reach_selection)
					&& (this.beg_current_selection < this.tmpMaxTimeLoaded)	)	{
				// alert('about to GoToBegSelection');
				this.GoToBegSelection();
				this.flag_should_set_position_when_loading_reach_selection = false;
			}
			
		}
		
		if (opts.onLoadingUpdate) 	{	opts.onLoadingUpdate(this.chargement/10);	}
		if(this.flash_movie) {
			this.flash_movie.sendChargementToFlash(this.chargement/10);
		}

		
		this.update_chargement_called_at_least_once = true;	
		// this.FocusToTheVideo();
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug  : UpdateChargement().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},

// Launched 5 seconds after the writing of the players to see if everything had been done correctly at this time
// otherwise, try to do the necessary adjustement, late updates...
CheckThePluginIsLoaded: function()	{
	// var thisVideo = this.plugin_to_register_events;	
		// alert('Arrived in CheckThePluginIsLoaded');
	try	{
		var thisVideo, thisPluginStatus;
		thisVideo = document.movie1;	
		thisPluginStatus = thisVideo.GetPluginStatus();
		// ”Error: <error number>”
		if (thisPluginStatus.match(/^Error:\s*(\d*)/))	{
			// alert("Little checking of the state of the plug-in :A: " + thisPluginStatus);
			window.location.reload();
		}	else if (!this.late_stuff_are_done)	{
			this.LaunchABitLater();
			// alert('LaunchABitLater Done within CheckThePluginIsLoaded. Will check again in 5s');
			this.CheckThePluginIsLoaded.bind(this).delay(5);
		}	else if (!this.events_are_registred)	{
			this.RegisterEvents();
			// alert('RegisterEvents Done within CheckThePluginIsLoaded.  Will check again in 5s ');
			this.CheckThePluginIsLoaded.bind(this).delay(5);
		}	else	{
			// alert('plug-in is checked CheckThePluginIsLoaded');
		}
	} catch(e) {
		// alert(this.tooltips.mes_plugin_not_yet_ready);
		this.CheckThePluginIsLoaded.bind(this).delay(5);
	}			
},

/************************************************************************/
/*		OraoWebSound OraoWebRadio Sound Radio sound radio part			*/
/************************************************************************/

GetFlashMovie: function(movieName) {
	var isIE = navigator.appName.indexOf("Microsoft") != -1;
	return (isIE) ? window[movieName] : document[movieName];
},

CallTheContentWhenFlashIsReady: function()	{
	// alert('About to Ajax URL ' + this.movie_options.url_lvl_xml);

	try {
		new Ajax.Request(this.movie_options.url_lvl_xml,
			{
				method:'get',
				evalJS:false,
				evalJSON:false,
				sanitizeJSON:false,
				onSuccess: function(response){
					try {
						// alert('onSuccess Reponse From the Ajax Request came back');
						var responseTXT, dataTagValues;
						responseTXT = response.responseText || "no response text";
						dataTagValues = new Hash();

						// var interestingPart = '';
						responseTXT.gsub(/<(data\d+_\w+)>([^<]*)/, function(match){ 
							dataTagValues.set(match[1], match[2]);
						});

						// dataTagValues.each(function(pair) {
						// 	interestingPart = interestingPart + "\n<h3>Key : " + pair.key + ' : </h3>' + pair.value + '<hr/>';
						// });

						// alert('About to send : data320_GM\n' + dataTagValues.get('data320_GM'));
						this.flash_movie.sendValuesToFlash(	dataTagValues.get('data320_GM'), 
															dataTagValues.get('data320_Gm'), 
															dataTagValues.get('data320_DM'), 
															dataTagValues.get('data320_Dm'), 
															dataTagValues.get('data1_GM'), 
															dataTagValues.get('data1_Gm'), 
															dataTagValues.get('data1_DM'), 
															dataTagValues.get('data1_Dm')
															);

						if (this.chargement != 0)	{
							this.flash_movie.sendChargementToFlash(this.chargement/10);
						} else 	{
							this.UpdateChargement(null);
						}
						if (this.end_current_selection != 0)	{
							this.flash_movie.sendSelectionToFlash(100*this.beg_current_selection/this.duration, 100*this.end_current_selection/this.duration);
						}
						// $('result').update(interestingPart);
					}
					catch (err) { 
						if (this.movie_options.debug_mode2)	{
							alert('Ref: BugAjaxOnSuccess().'
								+ '\nName: ' + err.name + '\nMessage: ' + err.message);
						}
					}
				}.bind(this),
				onFailure: function(){ 
					if (this.movie_options.debug_mode2)	{
						alert('Ref: BugAjax, from onFailure'
							+ '\nErreur probable : l\'URL de la requete Ajax de l\'enveloppe du son ne pointe pas vers un document xml valide : ' + '\nURL xml : ' + this.movie_options.url_lvl_xml);
					}	else	{
						alert('L\'enveloppe graphique du son n\'est pas lisible (ou son adresse n\'est pas valide). Contactez l\'administrateur du site / This page can not reach the sound shape. Please contact the web admin'); 
					}
				},
				onException: function(){
					if (this.movie_options.debug_mode2)	{
						alert('Ref: BugAjax, from onException'
							+ '\nErreur probable : l\'URL de la requete Ajax de l\'enveloppe du son n\'est pas sur le même serveur que le player : ' + '\nURL xml : ' + this.movie_options.url_lvl_xml + '\nURL page : ' + document.location.href);
					}	else	{
						alert('L\'enveloppe graphique du son n\'est pas lisible (ou son adresse n\'est pas la même que la page du player). Contactez l\'administrateur du site / This page can not reach the sound shape. Please contact the web admin');
					}
				}.bind(this),
				onComplete: function(transport){
					// if (this.movie_options.debug_mode2)	{
					// 	alert('Ref: Ajax Completed'
					// 		+ '\nTransport Status : '  + transport.status );
					// }
				}.bind(this)
			}
		);
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: BugAjax'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
	// return(this.movie_options.name_of_javascript_object);
	return('OK');
},


/************************************************************************/
/*				Main parts and Interactions								*/
/************************************************************************/

PlayTheVideo  : function() {	
	if (this.button_to_default_back != '')	{
		$$('#' + this.button_to_default_back + ' img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images[this.button_to_default_back]);
		this.button_to_default_back = '';
	}

	if (this.manual_rewind_timer) {
		this.manual_rewind_timer.stop();
		this.rewind_speed=0;
	}
	this.resetJogleIfNecessary();
	if((this.plugin_status=='OK') && (! this.reach_the_end))	{
		
		this.ResetTheSelectionIfNeeded();
		
		this.theVideo.Play();
		if (this.button_play_pause_exist)	{ 
			$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images.ow_bouton_pause);
		}
		this.reach_the_beginning = false;
	}
	this.FocusToTheVideo();
},


StopTheVideo  : function() {
	try {
		if (this.button_to_default_back != '')	{
			$$('#' + this.button_to_default_back + ' img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images[this.button_to_default_back]);
			this.button_to_default_back = '';
		}

		if (this.manual_rewind_timer) {
			this.manual_rewind_timer.stop();
			this.rewind_speed=0;
		}
		this.resetJogleIfNecessary();
		this.theVideo.Stop();

		if (this.button_play_pause_exist)	{ 
			$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images.ow_bouton_play);
		}
		this.movie_time = this.theVideo.GetTime();
		$('ow_id_timecode').update(this.timecode());	
		this.FocusToTheVideo();
		this.flag_media_stopped_once = true;
		
		
	}
	catch (err) { 
		// Pierre7
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug StopTheVideo : StopTheVideo this.theVideo.Stop().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},


ToggleTheVideo  : function() {
	//alert('GetRate : '+this.theVideo.GetRate() + ' / rewind_speed : ' + this.rewind_speed);
	try {
		if ( (this.theVideo.GetRate() == 0) && (this.rewind_speed == 0)){
			this.PlayTheVideo();
		} else {
			this.StopTheVideo();
		}
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug Pierre8 : ToggleTheVideo().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},

// manage the situation when one keep the step by step button pressed
StartTheStepping	: function(_step)	{
	this.StepTheVideo(_step);
	if(this.movie_options.debug_mode) 	{	$('debug1').update('StartTheStepping '+ (++this.debug1) );	}
	document.observe('mouseup', this.the_stop_the_stepping);
	this.timer_stepping_second_phase = 0;
	if(this.movie_options.debug_mode) 	{	$('debug3').update('UpdateStepping ' + this.timer_stepping_second_phase);	}
	if (this.timer_stepping) {
		this.timer_stepping.stop();
		this.timer_stepping = null;
	}
	this.timer_stepping = new PeriodicalExecuter( this.UpdateStepping.bind(this, _step), this.movie_options.start_the_stepping_after);
	if (_step>0)	{
	  if($$('#ow_bouton_step_forward img')[0]) {
		$$('#ow_bouton_step_forward img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images_pressed.ow_bouton_step_forward);
		this.button_to_default_back = 'ow_bouton_step_forward';
		}
	}	else	{
		if($$('#ow_bouton_step_rewind img')[0]) {
			$$('#ow_bouton_step_rewind img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images_pressed.ow_bouton_step_rewind);
			this.button_to_default_back = 'ow_bouton_step_rewind';
		}
	}
},

// when one release the step by step button
StopTheStepping	: function()	{
	// alert('StopTheStepping');
	if(this.movie_options.debug_mode) 	{	$('debug1').update('StopTheStepping '+ (--this.debug1));	}
	
	this.timer_stepping.stop();
	this.timer_stepping = null;
	document.stopObserving('mouseup', this.the_stop_the_stepping);

	$$('#' + this.button_to_default_back + ' img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images[this.button_to_default_back]);
	this.button_to_default_back = '';
},

// See StartTheStepping
UpdateStepping	: function(_step)	{
	this.timer_stepping_second_phase++;
	// if(this.movie_options.debug_mode) {	$('debug3').update('UpdateStepping ' + this.timer_stepping_second_phase);	}
	if (this.timer_stepping_second_phase == 1)	{
		this.timer_stepping.changeFrequency(this.movie_options.stepping_frequency);
	}
	this.ShortStepTheVideo(_step);
},

// See StartTheStepping
ShortStepTheVideo  : function(_step) {
	// if(this.movie_options.debug_mode) 	{	$('debugPos').update('Short StepTheVideo of '+ _step + ' / ' + this.debugPos++);	}
	try {
		this.theVideo.Step(_step);		
		this.movie_time = this.theVideo.GetTime();
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug ShortStepTheVideo().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}

	$('ow_id_timecode').update(this.timecode());
	
	if (_step < 0)	{
		this.reach_the_end = false;
	} else if (_step > 0)	{
		this.reach_the_beginning = false;
	}
	
	this.FocusToTheVideo();
},

// Step th evideo with a given step value
StepTheVideo  : function(_step) {
	// if(this.movie_options.debug_mode) $('debugPos').update('StepTheVideo of '+ _step + ' / ' + this.debugPos++);
	// alert('StepTheVideo with Step = '+ _step);
	// _repeatTheStepAfterXSeconds = 1 => we are waiting for a release of the mouse to stop an automatic stepping
	// the value give the time we have to wait before 
	if (this.button_to_default_back != '')	{
		$$('#' + this.button_to_default_back + ' img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images[this.button_to_default_back]);
		this.button_to_default_back = '';
	}
	
	this.theVideo.Stop();
	if (this.manual_rewind_timer)	{
		this.manual_rewind_timer.stop();
		this.rewind_speed=0;
	}
	this.resetJogleIfNecessary();
	if (this.button_play_pause_exist)	{ 
		$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images.ow_bouton_play);
	}
	if (this.manual_rewind_timer) {
		this.manual_rewind_timer.stop();
		this.rewind_speed=0;
	}
	
	this.ResetTheSelectionIfNeeded();
	
	try {
		this.theVideo.Step(_step);
		
		this.movie_time = this.theVideo.GetTime();
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug StepTheVideo().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}

	$('ow_id_timecode').update(this.timecode());
	
	if (_step < 0)	{
		this.reach_the_end = false;
	} else if (_step > 0)	{
		this.reach_the_beginning = false;
	}
	
	this.FocusToTheVideo();
},

// Called when the mouse go up AND the advance_jog_shuttle option is false
ReleaseOfTheJogShuttle	: function()	{
	document.stopObserving('mouseup', this.theReleaseOfTheJogShuttle);
	this.StopTheVideo();
	this.jog_was_slided = false;
	this.jog_was_slided_and_set = true;
	this.jog_slider.setValue(2);
},


StartTimerPosition: function(_event)	{
	if (this.timer_position)	{
		this.timer_position.start();
	}	else	{
		this.OnEvent(_event);
	}
	
	if (this.button_play_pause_exist)	{ 
		$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images.ow_bouton_pause);
	}
	this.FocusToTheVideo();
},


StopTimerPosition:function(_event)	{
	this.timer_position.stop();
	if (this.button_play_pause_exist)	{ 
		if (this.rewind_speed < 0) {
			$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images.ow_bouton_pause);
		}	else	{
			$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images.ow_bouton_play);
		}
	}
	this.resetJogleIfNecessary();
	// debut modif version 3.1.4
	// this.UpdatePosition();  // One last time ? 
	// Ne prenons pas de risque : c'est surtout ce qui suit qui compte
	this.movie_time = this.theVideo.GetTime();
	$('ow_id_timecode').update(this.timecode());	
	// Fin de la modif pour version 3.1.4
	this.FocusToTheVideo();
},



FocusToTheVideo: function()	{
	// this.plugin_to_register_events.focus();
	document.movie1.focus();
	// document.movie1emb.focus();
	// $('movieplayer').focus();
},


// Fonction appelee regulierement pour positionner correctement la timeline 
UpdatePosition: function(timer) {
	try {
		// if(this.movie_options.debug_mode) $('debugPos').update(this.debugPos++);
		// if less than one frame since the last update, just forget it
		var time = new Date().getTime();
		if (	( time - this.time_last_position_update ) < this.min_time_between_position_update	)	{
			// if(this.movie_options.debug_mode) $('debug2').update('Positions jumped over '+ this.debug2++ + ' / '+ ( time - this.time_last_position_update ));
			// alert ('too Fast')
			return(false);
		}				

		if (this.duration > 0)	{
			this.movie_time = this.theVideo.GetTime();
			this.new_position = Math.round(this.movie_time/this.duration * 1000);
			if (	(this.new_position>this.chargement-10)	 &&
			 		(this.chargement < 999)	){
				// if (this.new_position>5)	{
				// 	alert('Called UpdateChargement because the loading event did not arrived in time'); 
				// }
				this.UpdateChargement(null);
			}
			this.rate = this.theVideo.GetRate();

			//if(this.movie_options.debug_mode) $('debug2').update('NP'+this.new_position+' R'+this.rate);
			//	DEBUG071109 this.new_position<100 =  this.new_position<10
			// 		des clics vers le debut de la barre de progression cause des sauts en fin de barre
			// 		risque potentiel de dereglage de la protection en avance rapide
			//		if ( (this.rate>0) && ( ( (this.new_position<position) && (this.new_position<100) ) || (this.new_position>998) ) )	
			if  (this.rate>0)	{
				if (this.rewind_speed < 0) {
					this.manual_rewind_timer.stop();
					this.rewind_speed=0;
				}
				if (	((this.new_position<this.position) && (this.new_position<10))	
						||	(this.new_position>998)	) {	
					// Quand QT retourne au debut de la video apres avoir atteint le bout
					// ou quand on arrive a la fin de la video
				this.EndOfVideo();
				}
			}   
			else if (	(this.rate<0)  
						&&	(  ((this.new_position>this.position) && (this.new_position>990)) 
							||	(this.new_position < 2) 	)	)	{
				// Quand on saute a la fin de la video apres avoir atteint 
				// le debut en retour rapide
				// ou quand on arrive au debut de la video
				if (this.rewind_speed < 0) {
					this.manual_rewind_timer.stop();
					this.rewind_speed=0;
				}
				this.theVideo.Stop();
				if (this.button_play_pause_exist)	{ 
					$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images.ow_bouton_play);
				}
				this.new_position = 0;
				this.movie_time = 0;
				this.theVideo.SetTime(0);
				$('ow_id_timecode').update(this.timecode());
				this.reach_the_end = false;
				this.reach_the_beginning = true;				
			}	
			// else if ( (this.rate == 0) &&  (this.new_position>998) )	{			
			// Le tempon precedent etait util quand on coupait le timer position quand une video atteignait la fin, ce qui n'est plus le cas aujourd'hui	
			else if ( (this.rate === 0) &&  (this.new_position>=1000) && (! this.movie_options.doNothingOnMovieFinished) )	{			
				// Quand QT arrive a la fin et s'arrete sans que javascript 
				// n'ai eu le temps de le detecter
				this.EndOfVideo();
			}
			if (this.new_position != this.position)	{
				if (!this.context_update_position)	{
					// if(this.movie_options.debug_mode) $('debug1').update('Position updated '+ this.debug1++);
					this.context_update_position=true;
					this.position_slider.setValue(this.new_position, 0);	
					this.context_update_position=false;
					this.position = this.new_position;						
				}
			}
			$('ow_id_timecode').update(this.timecode());
			this.time_last_position_update = new Date().getTime();
			
			// if(this.movie_options.sound_level) 	{//   Cas du sound son
			if(this.flash_movie) 	{//   Cas du sound son avec le movie Flash déjà initialisé
				this.flash_movie.sendPositionHeaderToFlash(this.movie_time/this.duration * 100, this.rate);
			}
		}
		// Cas IE : n'ecoute pas les evennemnet de redimensionnement avant la fin du cahargement
		if (!this.chargement_done && this.chargement < 980 
			&& Prototype.Browser.IE && this.movie_options.automaticallyAdjustSize)	{
			this.AutomaticFitIntoNewScreen();
		}
		return true;
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug Pierre16 : UpdatePosition().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},


UpdatePosWhenRewind  : function() {
	try {
		this.date_for_rewind = new Date();
		this.new_time_for_rewind = this.date_for_rewind.getTime();
		this.new_position_for_rewind = this.last_position_for_rewind + ((this.new_time_for_rewind - this.last_time_for_rewind)/1000)  * this.rewind_speed * this.theVideo.GetTimeScale();
		if ( this.new_position_for_rewind<this.beg_current_selection ) {
			this.new_position_for_rewind = this.beg_current_selection;
			this.manual_rewind_timer.stop();
			this.rewind_speed=0;
			this.theVideo.Stop();
			this.resetJogleIfNecessary();
			if (this.button_play_pause_exist)	{ 
				$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images.ow_bouton_play);
			}
		}
		this.theVideo.SetTime(this.new_position_for_rewind);
		this.last_position_for_rewind = this.new_position_for_rewind;
		this.last_time_for_rewind = this.new_time_for_rewind;
		return true;
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug Pierre17 : UpdatePosWhenRewind().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},


resetJogleIfNecessary  : function() {
	if (this.jog_was_set)	{
		// This do not modify the status of the video, just the jog
		this.jog_was_slided_and_set = true;
		this.jog_was_set = false;
		this.jog_slider.setValue(2);
		if($('ow_id_jog_value'))	{
			$('ow_id_jog_value').update(' ');
		}
	}
},


FastRewind  : function() { 	// Called by the Fast Rewind button
	try {
		if (this.button_to_default_back == 'ow_bouton_fast_rewind')	{
			this.StopTheVideo();
			return;
		}	else if (this.button_to_default_back != '')	{
			$$('#' + this.button_to_default_back + ' img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images[this.button_to_default_back]);
			this.button_to_default_back = '';
		}
		
		if(this.plugin_status=='OK') {
			this.theVideo.Stop();
			if (this.manual_rewind_timer)	{
				this.manual_rewind_timer.stop();
				this.rewind_speed=0;
			}
			this.resetJogleIfNecessary();
			this.ResetTheSelectionIfNeeded();
			this.last_position_for_rewind = this.theVideo.GetTime();
			if( !this.reach_the_beginning && (this.last_position_for_rewind>this.beg_current_selection))	{
				if (this.button_play_pause_exist)	{ 
					$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images.ow_bouton_pause);
				}
				this.video_should_be_relaunched = false;
				this.rate = -2;
				if (this.GetQuicktimeDetector().isQTCompatible(this.quicktime_version, this.last_QT_version_for_manual_rewind ))	{
						// When the current version of Quicktime is not powerfull enough to do normal rewind, switch to manual
					// alert('Fast Rewind en Manuel');
					this.rewind_speed = -2;
					this.date_for_rewind = new Date();
					this.last_time_for_rewind = this.date_for_rewind.getTime();
					this.last_position_for_rewind = this.theVideo.GetTime();
					if (this.manual_rewind_timer)	{
						this.manual_rewind_timer.start();
					}	else	{
						this.manual_rewind_timer = new PeriodicalExecuter( this.UpdatePosWhenRewind.bind(this), 0.09);
					}			
				}	else	{
					// alert('Fast Rewind en SetRate');
					this.theVideo.SetRate(-2);
				}
				this.reach_the_end = false;
				$$('#ow_bouton_fast_rewind img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images_pressed.ow_bouton_fast_rewind);
				this.button_to_default_back = 'ow_bouton_fast_rewind';
			}
		} else	{
			// alert('Fast Rewind can\'t start : plug-in NOK');
		}
		this.FocusToTheVideo();
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug Pierre18 : FastRewind().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},


FastForward  : function() { 	// Called by the Fast Foward button
	try {
		if (this.button_to_default_back == 'ow_bouton_fast_forward')	{
			this.StopTheVideo();
			return;
		}	else if (this.button_to_default_back != '')	{
			$$('#' + this.button_to_default_back + ' img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images[this.button_to_default_back]);
			this.button_to_default_back = '';
		}

		if(this.plugin_status=='OK')	{
			this.theVideo.Stop();
			this.ResetTheSelectionIfNeeded();
			if (this.manual_rewind_timer)	{
				this.manual_rewind_timer.stop();
				this.rewind_speed=0;
			}
			this.resetJogleIfNecessary();
			this.last_position_for_rewind = this.theVideo.GetTime();
			if(	!this.reach_the_end	&&	(this.last_position_for_rewind < this.end_current_selection)	)	{
				if (this.button_play_pause_exist)	{ 
					$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images.ow_bouton_pause);
				}
				this.video_should_be_relaunched = false;
				this.rate = 2.5;
				this.theVideo.SetRate(2.5);
				this.reach_the_beginning = false;
				
				$$('#ow_bouton_fast_forward img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images_pressed.ow_bouton_fast_forward);
				this.button_to_default_back = 'ow_bouton_fast_forward';
			} else	{
				// alert('Fast Forward can\'t start : this.reach_the_end = true  or this.last_position_for_rewind >= this.end_current_selection');
			}
			
		} else	{
			// alert('Fast Forward can\'t start : plug-in NOK');
		}
		this.FocusToTheVideo();
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug Pierre19 : FastForward().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},


GoToPercent: function(_percent){
	try {
		if (_percent<100) 	{	this.reach_the_end = false;	}
		var t = Math.round(_percent * this.duration / 100);
		if(t<=this.theVideo.GetMaxTimeLoaded()){
			this.theVideo.SetTime(t);
			// this.FocusToTheVideo();
			return(_percent);
		}	else	{
			this.theVideo.SetTime(this.theVideo.GetMaxTimeLoaded());
			// this.FocusToTheVideo();
			return(this.theVideo.GetMaxTimeLoaded()/this.duration * 100);
		}
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug Pierre22 : GoToPercent().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},

// Part of the Public API.  _timecode should take into account timecode_lag as set in the calling parameters
GoToLongTimeCode: function(_timecode){
	try {
		var opts, maxTime, qtTime;
		opts = this.movie_options;

		this.StopTheVideo();
		this.reach_the_end = false;
		maxTime = this.theVideo.GetMaxTimeLoaded();
		qtTime = this.LongTimeCodeToQTTime(_timecode) - opts.timecode_lag_in_second*this.movie_time_scale;
		
		if(qtTime<=maxTime){
				this.theVideo.SetTime(qtTime);
				this.movie_time = qtTime;					
		}	else	{
			return false;
		}
		this.position = Math.round(this.movie_time/this.duration * 1000);
		this.reach_the_beginning = true;
		if (!this.context_update_position)	{
			this.context_update_position=true;
			this.position_slider.setValue(this.position, 0);	
			this.context_update_position=false;
			$('ow_id_timecode').update(this.timecode());
		}
		return true;
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: GoToLongTimeCode().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},

/****************************************************************/
/*		Selection process ...									*/
/****************************************************************/

GoToBegSelection	: function()	{
	try {
		this.StopTheVideo();
		this.reach_the_end = false;
		var maxTime = this.theVideo.GetMaxTimeLoaded();
		
		if(this.beg_current_selection<=maxTime){
				this.theVideo.SetTime(this.beg_current_selection);
				this.movie_time = this.beg_current_selection;					
		}	else	{
			this.theVideo.SetTime(maxTime);
			this.movie_time = maxTime;
		}
		this.position = Math.round(this.movie_time/this.duration * 1000);
		this.reach_the_beginning = true;
		if (!this.context_update_position)	{
			this.context_update_position=true;
			this.position_slider.setValue(this.position, 0);	
			this.context_update_position=false;
			$('ow_id_timecode').update(this.timecode());
		}
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug Pierre11 : this.theVideo.GetRate().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},


GoToEndSelection	: function()	{
	try {
		this.StopTheVideo();			
		this.reach_the_beginning = false;
		var maxTime = this.theVideo.GetMaxTimeLoaded();			
		// alert('GoTo  : '+this.end_current_selection+' / duration : '+this.duration);
		
		if(this.end_current_selection<=maxTime){
				this.theVideo.SetTime(this.end_current_selection);
				this.movie_time = this.end_current_selection;
				this.reach_the_end = true;
		}	else	{
			this.theVideo.SetTime(maxTime);
			this.movie_time = maxTime;
		}
		if (!this.context_update_position)	{
			this.context_update_position=true;
			this.position_slider.setValue(this.position, 0);	
			this.context_update_position=false;
			$('ow_id_timecode').update(this.timecode());
		}
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug Pierre12 : this.theVideo.GetRate().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},

// An Orao selection is set, but not forwarded to Quicktime (typically, when one want to extend an existing one)
// One have to synchronise the two selection mode
ResetTheSelectionIfNeeded : function()	{
	if (this.flag_sub_selection_set && this.flag_sub_selection_QT_tmp_unset)	{		// une selection est deja en cours
						// Mais cette selection n'est pas active au niveau de QT
		try {
			this.movie_time = this.theVideo.GetTime();
			if (( this.movie_time<this.beg_current_selection_vis )	|| ( this.movie_time>=this.end_current_selection_vis ) ) {
				this.movie_time = this.beg_current_selection_vis;
				this.theVideo.SetTime(this.movie_time);
				this.new_position = Math.round(this.movie_time/this.duration * 1000);
				$('ow_id_timecode').update(this.timecode());
			}
			
			this.theVideo.SetStartTime(this.beg_current_selection_vis);
			this.theVideo.SetEndTime(this.end_current_selection_vis);
			this.flag_sub_selection_QT_tmp_unset = false;
		}
		catch (err) { 
			// Pierre6
			if (this.movie_options.debug_mode2)	{
				alert('Ref: Bug ResetTheSelectionIfNeeded : this.theVideo.SetTime().'
					+ '\nName: ' + err.name + '\nMessage: ' + err.message);
			}
		}
	}
},


SetSelectionBar: function(_beginning, _end)	{
	var opts = this.movie_options;
	$('ow_navigation_selected_extract').setStyle({
		// width:Math.round((opts.position_slider_width)*(_end-_beginning)/1000)+'px',
		width:Math.round((opts.position_slider_width - opts.selection_adjust_cursor)*(_end - _beginning)/1000 + opts.selection_adjust_cursor - opts.selection_adjust_left - opts.selection_adjust_right)+'px',
	 	// left:Math.round(1+opts.position_slider_width*_beginning/1000)+'px' 
	 	left:Math.round(opts.selection_adjust_left + opts.position_slider_width*_beginning/1000)+'px' 
	});			
},


SetSelectionBarTarget: function(_beginning, _end)	{
	var opts = this.movie_options;
	$('ow_navigation_selected_target').setStyle({ 
		// width:Math.round(opts.position_slider_width*((_end - _beginning)/1000))+'px',
		width:Math.round((opts.position_slider_width - opts.selection_adjust_cursor)*(_end - _beginning)/1000 + opts.selection_adjust_cursor - opts.selection_adjust_left - opts.selection_adjust_right)+'px',
	 	// left:Math.round(1+opts.position_slider_width*_beginning/1000)+'px' 
	 	left:Math.round(opts.selection_adjust_left + opts.position_slider_width*_beginning/1000)+'px' 
	});			
},

// Part of the public API
SetSelectionAll: function(){		// specially used with ina who want to set the default status to everything selected
	try {
		var opts = this.movie_options;
		
		if (	(this.plugin_status == 'OK')	&&
				(this.chargement > 5 )	){
			if(!this.flag_sub_selection_set) { //we do that only if a selection hasn't been done manually before
				
				if(opts.timecode_OUT)	{
					this.tcOUT_in_QTTime = this.LongTimeCodeToQTTime(opts.timecode_OUT) - 
											opts.timecode_lag_in_second*this.movie_time_scale;
					this.tcOUT_in_QTTime = (this.tcOUT_in_QTTime <= this.duration ? 
											this.tcOUT_in_QTTime : this.duration);
				} 	else	{
					this.tcOUT_in_QTTime = this.duration;
				}
				if(opts.timecode_IN)	{
					this.tcIN_in_QTTime = this.LongTimeCodeToQTTime(opts.timecode_IN) - opts.timecode_lag_in_second*this.movie_time_scale;
					this.tcIN_in_QTTime = (this.tcIN_in_QTTime>=0 ? this.tcIN_in_QTTime : 0);
				} 	else	{
					this.tcIN_in_QTTime = 0;
				}
				
				if(this.tcIN_in_QTTime >= this.tcOUT_in_QTTime)	{
					this.tcOUT_in_QTTime = this.duration;
					if(this.tcIN_in_QTTime >= this.tcOUT_in_QTTime)	{
						this.tcIN_in_QTTime = 0;
						if(this.tcIN_in_QTTime >= this.tcOUT_in_QTTime)	{
							this.tcOUT_in_QTTime = 10;
						}
					}
				}

				
				this.beg_current_selection = this.tcIN_in_QTTime;
				this.end_current_selection = this.tcOUT_in_QTTime;
				this.SetSelection(	this.QTTimeToLongTimeCode(this.beg_current_selection),
									this.QTTimeToLongTimeCode(this.end_current_selection));
			}
		}	else	{
			this.SetSelectionAll.bind(this).delay(1);
			// alert('plug-in not yet ready for a SetSelectionAll. Will try again later. Loading :'+this.chargement);
		}
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: BugSetSelectionAll().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},

// Part of the public API
SetSelection: function(_begTC, _endTC)	{
	try {
			// Debug PVK
		// this.movie_time = this.theVideo.GetTime();
		// alert(' this.movie_time 1 : ' + this.movie_time + ' ('+ this.QTTimeToLongTimeCode(this.movie_time) +')/ _begTC: '+ _begTC +' -  _endTC: '+_endTC );
		var returnValue, opts, tmp, timecodeRegularExpression;
		
		returnValue = 1;
		opts = this.movie_options;
		
		timecodeRegularExpression  =  /^\d{2}:\d{2}:\d{2}(:|\.)\d{2}$/;
		if (_begTC.search(timecodeRegularExpression)==-1)	{
			return -10;
		}
		if (_endTC.search(timecodeRegularExpression)==-1)	{
			return -11;
		}
		
		this.flag_sub_selection_set = true;
		this.beg_current_selection_TC = _begTC;
		this.end_current_selection_TC = _endTC;
		
		this.beg_current_selection = this.LongTimeCodeToQTTime(_begTC) - opts.timecode_lag_in_second*this.movie_time_scale;
		this.end_current_selection = this.LongTimeCodeToQTTime(_endTC) - opts.timecode_lag_in_second*this.movie_time_scale;
		
		if (this.beg_current_selection > this.end_current_selection)	{
			tmp = this.beg_current_selection;
			this.beg_current_selection = this.end_current_selection;
			this.end_current_selection = tmp;
			returnValue = -1;
		}		
		
		
		if 	(this.tcIN_in_QTTime > this.beg_current_selection)	{
			this.beg_current_selection = this.tcIN_in_QTTime;
			returnValue = (returnValue == 1 ? -2 : -3);
		} 
		if (this.end_current_selection > this.tcOUT_in_QTTime) {
			this.end_current_selection = this.tcOUT_in_QTTime
			returnValue = (returnValue == 1 ? -4 : (returnValue == -1 ? -5 : -6));
		}		
		
		//   SetStartTime A Faire uniquement une fois le chargement terminé ? (c'est une question)
		// this.theVideo.SetStartTime(this.beg_current_selection);
		// this.theVideo.SetEndTime(this.end_current_selection);
		
		this.tmpMaxTimeLoaded = this.theVideo.GetMaxTimeLoaded();
		this.beg_current_selection_vis = (this.beg_current_selection > this.tmpMaxTimeLoaded ? this.tmpMaxTimeLoaded : this.beg_current_selection );
		this.end_current_selection_vis = (this.end_current_selection > this.tmpMaxTimeLoaded ? this.tmpMaxTimeLoaded : this.end_current_selection);
		

		//	Debug PVK
		// this.movie_time = this.theVideo.GetTime();
		// alert('.movie_time 2 : ' + this.movie_time + ' ('+ this.QTTimeToLongTimeCode(this.movie_time) +')/ this.beg_current_selection_vis: '+this.beg_current_selection_vis+ ' ('+ this.QTTimeToLongTimeCode(this.beg_current_selection_vis) +') -  this.end_current_selection_vis: '+this.end_current_selection_vis+ ' ('+ this.QTTimeToLongTimeCode(this.end_current_selection_vis) +')');

// XXXXX SetStartStime used to be set here
		//	Debug PVK
		// this.movie_time = this.theVideo.GetTime();
		// alert('.movie_time 3 : ' + this.movie_time + ' ('+ this.QTTimeToLongTimeCode(this.movie_time) +')/ this.beg_current_selection_vis: '+this.beg_current_selection_vis+ ' ('+ this.QTTimeToLongTimeCode(this.beg_current_selection_vis) +') -  this.end_current_selection_vis: '+this.end_current_selection_vis+ ' ('+ this.QTTimeToLongTimeCode(this.end_current_selection_vis) +')');
		
		this.SetSelectionBarTarget(1000*this.beg_current_selection/this.duration, 1000*this.end_current_selection/this.duration);	
		$('ow_navigation_selected_target').setStyle({ visibility:'visible' });
		
		this.SetSelectionBar(1000*this.beg_current_selection_vis/this.duration, 1000*this.end_current_selection_vis/this.duration);	
		$('ow_navigation_selected_extract').setStyle({ visibility:'visible' });
		$('ow_navigation_selected_extract').observe("mousedown", this.selectionEventHandler );
		
		if(this.flash_movie) 	{	
			this.flash_movie.sendSelectionToFlash(100*this.beg_current_selection/this.duration, 100*this.end_current_selection/this.duration);	
		}
	    
		this.flag_sub_selection_QT_tmp_unset = false;

		this.movie_time = this.theVideo.GetTime();
//		if (( this.movie_time<=this.beg_current_selection_vis )	|| ( this.movie_time>=this.end_current_selection_vis ) ) {
		// NOTE PVK : inequality strict or not ? this is the question. For Gaumont, it should be strict at the end
		//	this.movie_time_scale / 25  = 1 frame tolerance
		if (( this.movie_time<this.beg_current_selection_vis )	|| ( this.movie_time>(this.end_current_selection_vis + this.movie_time_scale / 25 ) ) ) {
			 // alert('Will GoToBegSelection : GetTimeScale : '+ this.theVideo.GetTimeScale() +' this.movie_time: ' + this.movie_time + ' ('+ this.QTTimeToLongTimeCode(this.movie_time) +')/ this.end_current_selection_vis: '+this.end_current_selection_vis+ ' ('+ this.QTTimeToLongTimeCode(this.end_current_selection_vis) +')');
			this.GoToBegSelection();
			// this.GoToLongTimeCode(_begTC);
		}
		else	{
			 // alert('DID NOT : GoToBegSelection : GetTimeScale : '+ this.theVideo.GetTimeScale() +' this.movie_time: ' + this.movie_time + ' ('+ this.QTTimeToLongTimeCode(this.movie_time) +')/ this.beg_current_selection_vis: '+this.beg_current_selection_vis+ ' ('+ this.QTTimeToLongTimeCode(this.beg_current_selection_vis) +') -  this.end_current_selection_vis: '+this.end_current_selection_vis+ ' ('+ this.QTTimeToLongTimeCode(this.end_current_selection_vis) +')');
		}
		this.theVideo.SetStartTime(this.beg_current_selection_vis);
		this.theVideo.SetEndTime(this.end_current_selection_vis);
		
		// version PVK 3.1.4e
		if (this.beg_current_selection > this.tmpMaxTimeLoaded)	{
			this.flag_should_set_position_when_loading_reach_selection = true;
		}	else	{
			if (this.flag_should_set_position_when_loading_reach_selection)	{
				// alert('about to GoToBegSelection');
				this.GoToBegSelection();
			}
			this.flag_should_set_position_when_loading_reach_selection = false;
		}
		return returnValue;
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug Pierre21 : SetSelection().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
		return 0;
	}
},


// catch the clic on the selection bar when that bar is above the the navigation bar and send the message to the navigation bar
SelectionReceiveAClick: function(theEvent)  {
	// alert("MouseDown : " + theEvent + ' Xpos : ' + theEvent.pointerX() +"\nCorrected : " + (theEvent.pointerX() - $('ow_navigation-slider').cumulativeOffset().left -3) +  "\nScaled : " + ((theEvent.pointerX() - $('ow_navigation-slider').cumulativeOffset().left -3)*1000/300)); 
	this.position = ((theEvent.pointerX() - $('ow_navigation-slider').cumulativeOffset().left -3)*1000/300) ;
	this.position_slider.setValue(this.position, 0);	
},


// Part of the public API
GetCurrentSelectionEnd: function()	{
	return this.QTTimeToLongTimeCode(this.end_current_selection);
},


// Part of the public API
GetCurrentSelectionBeginning: function()	{
	return this.QTTimeToLongTimeCode(this.beg_current_selection);
},

// Part of the public API
UnSetSelection: function()	{
	$('ow_navigation_selected_extract').stopObserving("mousedown", this.selectionEventHandler );
	
	if (this.beg_current_selection>this.tcIN_in_QTTime)	{
		this.reach_the_beginning = false;
	}
	this.beg_current_selection = this.tcIN_in_QTTime;
	if (this.end_current_selection < this.tcOUT_in_QTTime)	{
		this.reach_the_end = false;
	}
	this.end_current_selection = this.tcOUT_in_QTTime;

	this.theVideo.SetStartTime(this.beg_current_selection);
	this.theVideo.SetEndTime(this.end_current_selection);
	
	this.SetSelectionBar(0, 0);	
	$('ow_navigation_selected_extract').setStyle({ visibility:'hidden' });

	this.SetSelectionBarTarget(0, 0);	
	$('ow_navigation_selected_target').setStyle({ visibility:'hidden' });

	if(this.flash_movie) 	{	this.flash_movie.sendSelectionToFlash(0, 100);	}
	
	this.flag_sub_selection_set = false;
},


/****************************************************************/
/*		FullScreen / Fit Screen / Change Screen Size ...		*/
/****************************************************************/

// open full screen and kill all timers (or the other way arround :-)
// This is used when a new window is opened for the Full Screen
OpenFullScreen  : function() {
	var opts = this.movie_options;

	this.fs_window = window.open(opts.urlOfFullscreenPage, 'videoFS','top=0, left=0, toolbar=no, location=no, directories=no, status=no, scrollbars=no, resizable=no, directories=no, channelmode=yes');

	if (this.manual_rewind_timer) {
		this.manual_rewind_timer.stop();
		this.rewind_speed=0;
	}
	this.theVideo.Stop();
	if (this.button_play_pause_exist)	{ 
		$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  opts.imageRootURL+opts.images.ow_bouton_play);	
	}

// VP 9/02/10 : desactivation masquage player
//	this.theVideo.SetURL(opts.urlOfReplacementImage);
//	this.player_panel.style.visibility= 'hidden';
//
//	this.end_fullscreen_movie_panel.show();
//	this.end_fullscreen_movie_panel.removeClassName('ow_hiddenBelow');	
//	this.end_fullscreen_movie_panel.addClassName('ow_floatingAboveAll');		
},

// This one is used when changing the size of a window to go to full screen
// This is the usual behaviour of the player today
SwitchToFullScreen : function() {
	if (this.plugin_status=='OK')	{
		
		this.inner_width_before_FS = document.viewport.getWidth();
		this.inner_height_before_FS = document.viewport.getHeight();
		this.window_position_x_before_FS = (document.all ? window.screenLeft : window.screenX);
		this.window_position_y_before_FS = (document.all ? window.screenTop : window.screenY);
		
		// if (Prototype.Browser.IE) { 
		// 	this.BackToInitialPoUp(); 
		// } // This is just to fix yet another IE bug....
		this.flag_context_program_resize = true;
		
		
		window.moveTo(0,1);
		window.resizeTo(window.screen.availWidth,window.screen.availHeight);
		window.focus();

		// first guestimation of the offset
		this.offset_width 	= window.screen.availWidth - document.viewport.getWidth();	
		this.offset_height	= window.screen.availHeight - document.viewport.getHeight();

		this.FitIntoNewScreen(true);

		$('ow_bouton_fullscreen').onclick = this.FromFullScreenToPoUp.bind(this);
		$('ow_bouton_fullscreen').writeAttribute({
			'alt'	: this.tooltips.ow_bouton_fullscreen_close,
			'title'	: this.tooltips.ow_bouton_fullscreen_close	});

		if (this.movie_options.onMovieFullScreen) 	{	this.movie_options.onMovieFullScreen();	}
		this.flag_context_program_resize = false;
		
	}
},

// Called when a screen size change is detected
AutomaticFitIntoNewScreen : function() {
	try {
		var newtime, new_available_width, new_available_height;
		
		newtime = new Date().getTime();
		new_available_width = document.viewport.getWidth();
		new_available_height = document.viewport.getHeight();
		// alert("window resized : AutomaticFitIntoNewScreen");
		
		
		if (this.flag_context_program_resize)	{
			this.last_time_window_was_resized = newtime;
			// $('afficheInfos').update( 'context of a programmatically initiated resize' + newtime);
			this.flag_context_program_resize = false;
			return;	// false alert this in the context of a programmatically initiated resize
		}
		
		if (	( newtime - this.last_time_window_was_resized ) < (1.3*this.min_time_between_window_update)	)	{
			// $('afficheInfos').update( 'Too Fast between two resize event' + newtime);
			return;
		}

		if ((new_available_width == this.last_available_width) && (new_available_height == this.last_available_height))	{
			this.last_time_window_was_resized = newtime;
			// $('afficheInfos').update( 'Same size' + newtime);
			return;		
		}

		// $('afficheInfos').update( 'window resized : '+ newtime);
		this.last_time_window_was_resized = new Date().getTime() + this.min_time_between_window_update;
		this.FitIntoNewScreen.bind(this, false).delay(this.min_time_between_window_update/1000);
		if (this.movie_options.onMovieScreenSizeChanged) {
			this.movie_options.onMovieScreenSizeChanged.bind(this).delay((this.min_time_between_window_update*1.1)/1000);		
		}
		
		this.last_available_width = new_available_width;
		this.last_available_height = new_available_height;
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug AutomaticFitIntoNewScreen().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},

// Called when the screen size had been adjusted or after a Go to Full Screen or after a x2
FitIntoNewScreen : function(target_FS) {
	try {
		if (this.plugin_status=='OK')	{
			
			var new_available_width, new_available_height, _getWidth, _getHeight, newWidth, newHeight;
			
			// alert('FitIntoNewScreen');
			this.flag_context_program_resize = true;
			if (!this.flag_container_size_read_before_first_autofit)	{
				if (this.movie_options.container_width_after_FS)	{
					this.container_width = this.movie_options.container_width_after_FS;
					// alert('First Read of this.container_width from movie options : '+this.container_width);
				}	else	{
					this.container_width = this.container.getWidth();
					// alert('First Read of this.container_width from measurement : '+this.container_width);
				}
				
				this.flag_container_size_read_before_first_autofit = true;
			}
			
			new_available_width = document.viewport.getWidth();
			new_available_height = document.viewport.getHeight();
	
			if (!this.offset_height)	{
				if (this.movie_options.offset_height) { 
					this.offset_width 	= 	this.movie_options.offset_width;
					this.offset_height	= 	this.movie_options.offset_height;
				}	else 	{
					_getWidth 	= document.viewport.getWidth();
					_getHeight	= document.viewport.getHeight();
	
					window.resizeTo(this.movie_options.window_default_width + 40, this.movie_options.window_default_height + 220);
					this.offset_width = this.movie_options.window_default_width + 40 - document.viewport.getWidth();
					this.offset_height = this.movie_options.window_default_height + 220 - document.viewport.getHeight();
					window.resizeTo(_getWidth + this.offset_width, _getHeight + this.offset_height);
				}
			}
			
			if ((new_available_width < this.minimum_available_width - 18) || (new_available_height < this.minimum_available_height))	{
				// alert('new_available_height: '+new_available_height + ' / this.minimum_available_height: '+ this.minimum_available_height + "\nnew_available_width: "+new_available_width + ' / this.minimum_available_width: '+ this.minimum_available_width);
				this.last_time_window_was_resized = new Date().getTime() + this.min_time_between_window_update;
				this.BackToInitialPoUp.bind(this).delay(this.min_time_between_window_update/1000);
				return;		
			}
			
			if (target_FS)	{
				newWidth = document.viewport.getWidth() - this.movie_options.free_lateral_width_in_FS;
			}	else	{
				newWidth = document.viewport.getWidth() - this.movie_options.free_lateral_width;
			}
			// alert('newWidth / target_FS : ' + newWidth + ' / ' + target_FS);
			
			this.container.setStyle({ width: newWidth+'px'});
			newHeight = document.viewport.getHeight() - this.movie_options.free_vertical_height - this.movie_options.free_height_above;
			// alert('document.viewport.getHeight : '+document.viewport.getHeight()+' / this.movie_options.free_vertical_height :' + this.movie_options.free_vertical_height + ' / this.movie_options.free_height_above : '+ this.movie_options.free_height_above
			// + "\n / newHeight : "+newHeight);
			
			this.movie_panel.setStyle({ width: newWidth+'px', height: newHeight+'px'});	
	
			if (this.flag_first_FitIntoNewScreen && Prototype.Browser.IE )	{
				this.flag_first_FitIntoNewScreen = false;
				this.FitIntoNewScreenPart2.bind(this,newWidth, newHeight).delay(this.min_time_between_window_update*1.2/1000);
			}	else	{
				this.flag_first_FitIntoNewScreen = false;
				this.FitIntoNewScreenPart2(newWidth, newHeight);
			}
			
		}	else	{
			this.AutomaticFitIntoNewScreen();
		}
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug FitIntoNewScreen().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},

// Done after a small pause if first autoFit in IE
FitIntoNewScreenPart2 : function(newWidth, newHeight) {
	// alert('FitIntoNewScreenPart2 : '+newWidth + ' / ' + newHeight);
	var fittedScale, availableBoxScale;
	
	// alert('movie_panel Style : '+newWidth + ' / ' + newHeight);
	fittedScale = this.movie_options.width/this.movie_options.height;
	availableBoxScale = newWidth/newHeight;
	
	if ( this.movie_options.sound_level 	)	{
		$('ow_flash_player').setStyle({ width: newWidth+'px', height: newHeight+'px'});
		if ( this.flash_movie )	{
			if (availableBoxScale>=fittedScale)	{
				this.flash_movie.style.width = Math.round((newHeight-4) * fittedScale) +"px";
				this.flash_movie.style.height = (newHeight-4) +"px";
			}	else	{
				this.flash_movie.style.width = newWidth +"px";
				this.flash_movie.style.height = Math.round(newWidth / fittedScale) +"px";
			}
		}
	}	else	{	
		// Just plain Video
		if (this.movie_options.scale == 'tofit')	{
			if (availableBoxScale>=fittedScale)	{
				this.theVideo.height	= newHeight;
				this.theVideo.width		= Math.round(newHeight * fittedScale);
				// alert('availableBoxScale>=fittedScale : height:'+newHeight+ '  / width : '+ Math.round(newHeight * fittedScale));
			}	else	{
				this.theVideo.width 	= newWidth;
				this.theVideo.height	= Math.round(newWidth / fittedScale);
				// alert('availableBoxScale < fittedScale : height:'+Math.round(newWidth / fittedScale)+ '  / width : '+ newWidth);
			}
		}	else	{
			this.theVideo.width			= newWidth;
			this.theVideo.height		= newHeight;
			// alert('fit aspect newWidth / newHeight : '+newWidth+ '/'+newHeight);
		}
		this.movie_panel.setStyle({ width: this.theVideo.width+'px', height: this.theVideo.height+'px'});
	}
	
	if (this.sound_slider) 	{	this.sound_slider.setValue(this.last_sound_value); 	}	// display issue with IE
	if (this.jog_slider) { 			
			// display issue with IE
		this.jog_was_slided_and_set = true;
		this.jog_was_set = false;
		this.jog_slider.setValue(this.jog_sliderLastValue); 	
		if (this.jog_sliderLastValue)	{
			this.jog_was_set = true;
		}
	}
	
	this.last_available_width = document.viewport.getWidth();
	this.last_available_height = document.viewport.getHeight();
	
	
	if (Prototype.Browser.IE)	{
		$('ow_id_timecode').update(this.timecode());	// display issue with IE
	}
	
	this.flag_context_program_resize = false;
},


// Back from FullScreen by resizing the window
FromFullScreenToPoUp : function() {
	try {
		if (this.plugin_status=='OK')	{
		
			this.flag_context_program_resize = true;
				
			window.resizeTo(this.inner_width_before_FS + this.offset_width , this.inner_height_before_FS + this.offset_height);
			if(!this.offset_tl_set)	{
				window.moveTo(1,22);
				this.offset_left = (document.all ? window.screenLeft : window.screenX) - 1;
				this.offset_top = (document.all ? window.screenTop : window.screenY) - 22;
				this.offset_tl_set = true;
			}
			window.moveTo(this.window_position_x_before_FS - this.offset_left,this.window_position_y_before_FS - this.offset_top);			
			window.focus();							


			this.FitIntoNewScreen(false);

			$('ow_bouton_fullscreen').onclick = this.SwitchToFullScreen.bind(this);
			$('ow_bouton_fullscreen').writeAttribute({
				'alt'	: this.tooltips.ow_bouton_fullscreen_open,
				'title'	: this.tooltips.ow_bouton_fullscreen_open	});

			if (this.movie_options.onMovieEndFullScreen) 	{	this.movie_options.onMovieEndFullScreen();	}
			this.flag_context_program_resize = false;
		
		}
	}
	catch (err) { 
		this.FromFullScreenToPoUp.bind(this).delay(1);
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug FromFullScreenToPoUp().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},

// Back To Initial Size of the window
BackToInitialPoUp : function() {
	try {
		// alert('BackToInitialPoUp');
		this.flag_context_program_resize = true;
		var opts, _offset_width, _offset_height;
		
		opts = this.movie_options;

		if (this.movie_options.sound_level && this.flash_movie)	{
			$('ow_flash_player').setStyle({ width: opts.width+'px', height: opts.height+'px'});
			this.flash_movie.style.width = opts.width +"px";
			this.flash_movie.style.height = (opts.height - 2)	 +"px";
		}	else	{	// Just plain Video
			this.theVideo.width	= opts.width;
			this.theVideo.height= opts.height;
		}
		
		this.container.setStyle({ width: this.container_width+'px' });
		this.movie_panel.setStyle({ width: opts.width+'px', height: opts.height+'px'});
		// if(window.console) {
		// 		window.console.log("this.container_width : " + this.container_width);
		// } 
		
		
		$('ow_bouton_fullscreen').onclick = this.SwitchToFullScreen.bind(this);
		$('ow_bouton_fullscreen').writeAttribute({
			'alt'	: this.tooltips.ow_bouton_fullscreen_open,
			'title'	: this.tooltips.ow_bouton_fullscreen_open	});
		if (this.sound_slider) 	{	this.sound_slider.setValue(this.last_sound_value); 	}	// display issue with IE
		if (this.jog_slider) { // display issue with IE
			this.jog_was_slided_and_set = true;
			this.jog_was_set = false;
			this.jog_slider.setValue(this.jog_sliderLastValue); 	
			if (this.jog_sliderLastValue)	{
				this.jog_was_set = true;
			}	
		}
		

		window.moveTo(opts.window_position_x, opts.window_position_y);			
		window.resizeTo(this.minimum_available_width + this.offset_width, this.minimum_available_height + this.offset_height);
		// alert('window.resizeTo: ' + (this.minimum_available_width) + ' / '+ (this.offset_width) + ' / ' + (this.minimum_available_height) + ' / ' + (this.offset_height));
		// alert('window.resizeTo: ' + (opts.window_default_width) + ' / '+ (this.offset_width) + ' / ' + (opts.window_default_height) + ' / ' + (this.offset_height));
		window.moveTo(opts.window_position_x, opts.window_position_y);			

		// second guestimation of the offset
		// necessary because Firefox mixed up its full screen available height on MacOSX
		_offset_width 	= this.minimum_available_width + this.offset_width - document.viewport.getWidth();
		_offset_height	= this.minimum_available_height + this.offset_height - document.viewport.getHeight();
		if ((this.offset_width != _offset_width) || (this.offset_height != _offset_height)) {
			this.offset_width = _offset_width;
			this.offset_height = _offset_height;
			window.resizeTo(this.minimum_available_width + this.offset_width, this.minimum_available_height + this.offset_height);				
			// alert('NEW offset : '+ this.offset_width + ' , '+ this.offset_height );
		}

		window.focus();
		// alert('window.moveTo: ' + (opts.window_position_x) + ' / ' + (opts.window_position_y));
		window.moveTo(opts.window_position_x, opts.window_position_y);			

		if (this.sound_slider) 	{	this.sound_slider.setValue(this.last_sound_value); 	}	// display issue with IE
		if (this.jog_slider) { // display issue with IE
			this.jog_was_slided_and_set = true;
			this.jog_was_set = false;
			this.jog_slider.setValue(this.jog_sliderLastValue); 	
			if (this.jog_sliderLastValue)	{
				this.jog_was_set = true;
			}
		}
		$('ow_id_timecode').update(this.timecode());	// display issue with IE

		// if (this.movie_options.onMovieEndFullScreen) 	{	this.movie_options.onMovieEndFullScreen();	}
		if (this.movie_options.onMovieScreenSizeChanged) {
			this.movie_options.onMovieScreenSizeChanged.bind(this).delay((this.min_time_between_window_update*1.1)/1000);		
		}

		this.last_available_width = document.viewport.getWidth();
		this.last_available_height = document.viewport.getHeight();
		this.flag_context_program_resize = false;
	}
	catch (err) { 
		this.BackToInitialPoUp.bind(this).delay(1);
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug BackToInitialPoUp().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},


/************************************************************************/
/*		End behaviour and Panel and other complimentary panel ...		*/
/************************************************************************/

// Called when one (Quicktime) reach the end of the video
EndOfVideo  : function() {
	try {
		this.theVideo.Stop();
		if (this.button_play_pause_exist)	{ 
			$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images.ow_bouton_play);
		}
		
		if (! this.movie_options.doNothingOnMovieFinished)	{				
			this.new_position = 0;
			this.position = 0;
			this.theVideo.SetTime(0);
			this.movie_time = 0;

			this.player_panel.style.visibility= 'hidden';
			this.end_movie_panel.show();
			this.end_movie_panel.removeClassName('ow_hiddenBelow');	
			this.end_movie_panel.addClassName('ow_floatingAboveAll');		
		}	else	{
			this.movie_time = this.theVideo.GetEndTime();
			this.theVideo.SetTime(this.movie_time);
			this.new_position = 1000;
			this.position = 1000;				
			
			this.reach_the_end = true;
			this.reach_the_beginning = false;				
		}
				
		if (!this.context_update_position)	{
			this.context_update_position=true;
			this.position_slider.setValue(this.new_position, 0);	
			this.context_update_position=false;
			this.position = this.new_position;
			$('ow_id_timecode').update(this.timecode());
		}

		if (this.movie_options.onMovieFinished)	{
			this.movie_options.onMovieFinished();
		}
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug Pierre10 : this.theVideo.GetRate().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},

// When doNothingOnMovieFinished is set to false, a panel is added when the video reach the end
// The following function is called when one click on the end movie panel
LetTheVideoBeVisibleAgain  : function() {
	this.player_panel.style.visibility= 'visible';

	if(this.end_fullscreen_movie_panel)	{
		this.end_fullscreen_movie_panel.removeClassName('ow_floatingAboveAll');
		this.end_fullscreen_movie_panel.addClassName('ow_hiddenBelow');
		this.end_fullscreen_movie_panel.hide();
	}
	
	this.end_movie_panel.removeClassName('ow_floatingAboveAll');
	this.end_movie_panel.addClassName('ow_hiddenBelow');
	this.end_movie_panel.hide();

	this.LetTheVideoBeVisibleAgainBis.bind(this).defer();
},

LetTheVideoBeVisibleAgainBis  : function() {	
	try {
		this.theVideo.SetRate(1);
		this.theVideo.Play();
		this.movie_time = this.theVideo.GetTime();
		$('ow_id_timecode').update(this.timecode());
		if (this.button_play_pause_exist)	{ 
			$$('#ow_bouton_play_pause img')[0].writeAttribute('src',  this.movie_options.imageRootURL+this.movie_options.images.ow_bouton_pause);
		}
	} catch (e) {
		alert('Looks like your browser can not catch back the video object. Please send an email to oroa@opsomai.com\nMessage :'+ e.message);	
		this.LetTheVideoBeVisibleAgainBis.bind(this).delay(2);
	}
},

// Show the help panel, and the copyright info is the shift key is pressed
ShowHelpPanel: function(_event)	{
	if (_event) {
		_event.stop();
	}			
    
	if (this.help_panel.hasClassName('ow_helpFloatingAboveAll'))	{
		this.HideHelpPanel();
		return;
	}

	if (!this.movie_options.help_panel_target)	{	// in that case the help panel is attach to the container
		this.StopTheVideo();
		this.player_panel.style.visibility= 'hidden';
	}
	this.help_panel.show();
	this.help_panel.removeClassName('ow_hiddenBelow');	
	this.help_panel.addClassName('ow_helpFloatingAboveAll');
	this.help_panel.observe('click', this.HideHelpPanel.bindAsEventListener(this));		
	
	if (_event.shiftKey) {
		if (_event.altKey)	{
	        alert(this.copyright + "\nDeveloper : Pascal Vuylsteker");
		}	else	{
	        alert(this.copyright);
		}
    }		
},

HideHelpPanel: function(_event)	{
	if (_event) {
		_event.stop();
	}

	this.help_panel.removeClassName('ow_helpFloatingAboveAll');	
	this.help_panel.addClassName('ow_hiddenBelow');		
	this.help_panel.hide();
	this.help_panel.stopObserving();
	if (! this.movie_options.help_panel_target)	{	// in that case the help panel is attach to the container
		this.player_panel.style.visibility= 'visible';	
	}
		
},


/************************************************************************/
/*		SOUND 															*/
/************************************************************************/

SoundChangedFromQT	: function()	{ 
	try {
		if (this.sound_slider_set_volume_flag)	{
			this.sound_slider_set_volume_flag = false;
			return;
		}
		this.sound_slider.setValue(this.theVideo.GetVolume());
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug Pierre20 : SoundChangedFromQT().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
	}
},


SetSoundVolume: function(theVolume) {
	if(this.plugin_status=='OK') {
		this.sound_slider.setValue(theVolume);
	}
	this.FocusToTheVideo();
},

/************************************************************************/
/*		Utilities / Time conversion										*/
/************************************************************************/

// this.movie_time, this.movie_time_scale must had be set properly before the usage of this function
ShortTimeCode: function() {
	// take into account the lag (timecode_lag_in_second) !
	var i, s, m, h, hx, mx, sx;
	
	//i=(this.movie_time/this.movie_time_scale) + this.movie_options.timecode_lag_in_second;
	i=Math.round((this.movie_time/this.movie_time_scale) + this.movie_options.timecode_lag_in_second);
	if(i<0) 	{	i=-i;	}
	s = Math.floor(i%60);
	i=(i-s)/60;
	m = Math.floor(i%60);
	i=(i-m)/60;
	h = Math.floor(i%24);
	
	if(h<10) 	{	hx = "0"+h;	}
		else 	{	hx=h;		}
	if(m<10) 	{	mx = "0"+m;	}
		else 	{	mx=m;		}
	if(s<10) 	{	sx = "0"+s;	}
		else 	{	sx=s;		}
	return hx + ":" + mx + ":" + sx;
},

// return current timecode in the long format : 'hh:mn:ss:ff'
// Part of the public API
// take into account the lag (timecode_lag_in_second) !
GetCurrentLongTimeCode: function() {
	try {
		this.movie_time = this.theVideo.GetTime();
		if ( this.movie_time<this.tcIN_in_QTTime )	{
			this.movie_time = this.tcIN_in_QTTime;
			this.theVideo.SetTime(this.movie_time);
		}
		if ( this.movie_time>this.tcOUT_in_QTTime )	{
			this.movie_time = this.tcOUT_in_QTTime;
			this.theVideo.SetTime(this.movie_time);
		}
		$('ow_id_timecode').update(this.timecode());
		return this.LongTimeCode();
	}
	catch (err) { 
		if (this.movie_options.debug_mode2)	{
			alert('Ref: Bug Pierre23 : GetCurrentLongTimeCode().'
				+ '\nName: ' + err.name + '\nMessage: ' + err.message);
		}
		return('--:--:--:--');
	}
},

// return this.movie_time in the long format : 'hh:mn:ss:ff'
// this.movie_time, this.movie_time_scale must had been set properly before the usage of this function
// take into account the lag (timecode_lag_in_second) !
LongTimeCode: function() {
	var i, f, s, m, h, fx, hx, mx, sx;
	//i=((this.movie_time/this.movie_time_scale)+this.movie_options.timecode_lag_in_second)*25;
	i=Math.round(((this.movie_time/this.movie_time_scale)+this.movie_options.timecode_lag_in_second)*25);
	if(this.movie_options.debug_mode) $('debug2').update('movie_time '+ this.movie_time );

	if(i<0) 	{	i=-i;	}
	f =Math.floor(i%25);
	i=(i-f)/25;
	s = Math.floor(i%60);
	i=(i-s)/60;
	m = Math.floor(i%60);
	i=(i-m)/60;
	h = Math.floor(i%24);
	
	if(h<10) 	{	hx = "0"+h;	}
		else 	{	hx=h;		}
	if(m<10) 	{	mx = "0"+m;	}
		else 	{	mx=m;		}
	if(s<10) 	{	sx = "0"+s;	}
		else 	{	sx=s;		}
	if(f<10) 	{	fx = "0"+f;	}
		else 	{	fx=f;		}
	return hx + ":" + mx + ":" + sx+ ":" + fx;
},

// convert _qtTime parameter into a long Timecode format : 'hh:mn:ss:ff'
QTTimeToLongTimeCode: function(_qtTime) {
	var i, f, s, m, h, fx, hx, mx, sx;

	//i=((_qtTime/this.movie_time_scale)+this.movie_options.timecode_lag_in_second)*25;
	i=Math.round(((_qtTime/this.movie_time_scale)+this.movie_options.timecode_lag_in_second)*25);
	if(i<0) 	{	i=-i;		}
	f =Math.floor(i%25);
	i=(i-f)/25;
	s = Math.floor(i%60);
	i=(i-s)/60;
	m = Math.floor(i%60);
	i=(i-m)/60;
	h = Math.floor(i%24);
	
	if(h<10) 	{	hx = "0"+h;	}
		else 	{	hx=h;		}
	if(m<10) 	{	mx = "0"+m;	}
		else 	{	mx=m;		}
	if(s<10) 	{	sx = "0"+s;	}
		else 	{	sx=s;		}
	if(f<10) 	{	fx = "0"+f;	}
		else 	{	fx=f;		}
	return hx + ":" + mx + ":" + sx+ ":" + fx;
},

// this.movie_time_scale must had been set properly before the usage of this function
// And the Timecode is expected to be properly formated : 'hh:mm:ss:ff or hh:mm:ss.ff'
LongTimeCodeToQTTime: function(_timecode) {
	var h, m, s, f, qttime;
	h=parseInt(_timecode.substring(0,2),10);
	m=parseInt(_timecode.substring(3,5),10);
	s=parseInt(_timecode.substring(6,8),10);
	f=parseInt(_timecode.substring(9,11),10);
	qttime=(((h*60+m)*60+s)*25+f) * this.movie_time_scale / 25;
	return qttime;
},

// And the Timecode is expected to be properly formated : 'hh:mm:ss:ff or hh:mm:ss.ff'
LongTimeCodeToTimeInSecond: function(_timecode) {
	var h, m, s, f, time;
	h=parseInt(_timecode.substring(0,2),10);
	m=parseInt(_timecode.substring(3,5),10);
	s=parseInt(_timecode.substring(6,8),10);
	f=parseInt(_timecode.substring(9,11),10);
	time=(((h*60+m)*60+s)*25+f)/25;
	return time;
},


/************************************************************************/
/*		Utilities / Time conversion										*/
/************************************************************************/

DetachMovie: function() {
	// alert('About to detach movie');
	try {
		this.StopTheVideo();
		var movie;
		try {
			movie = document.getElementById(this.movie_options.name);
			if (movie != null) {
				movie.style.display = 'none';
				this.movie_panel.removeChild(movie);
				movie = null;
			}
		} catch(e) {
			// alert('Pas Glop')
			
			try {
				movie = document.getElementsByName(this.movie_options.name)[0];
				if (movie != null) {
					movie.style.display = 'none';
					this.movie_panel.removeChild(movie);
					movie = null;
				}
			} catch (e2) {
				// alert('Pas Glop 2')
			}
		}
		try	{
			this.theVideo.remove();
		}	catch (e3) {}
						
		this.movie_panel.remove();
		this.controller_panel.remove();
		if (this.end_movie_panel) 	{	this.end_movie_panel.remove();	}
		if (this.end_fullscreen_movie_panel) 	{	this.end_fullscreen_movie_panel.remove();	}
		this.player_panel.remove();
		this.container.remove();
	} catch (e4) {
		// alert ('Too Much');
	}

	this.theVideo	 	= null;
	this.movie_panel	= null;
	// alert('Movie detached');
},

GetQuicktimeDetector: function() {
	return {
		isQTInstalled:function(){
			var U, M, g;
			U=false;
			if(navigator.plugins&&navigator.plugins.length){
				for(M=0;M<navigator.plugins.length;M++){
					g=navigator.plugins[M];
					if(g.name.indexOf("QuickTime")>-1){
						U=true;
					}
				}
			}else{
				qtObj=false;
				execScript("on error resume next: qtObj = IsObject(CreateObject(\"QuickTimeCheckObject.QuickTimeCheck.1\"))","VBScript");
				U=qtObj;
			}
			return U;
		},
		getQTVersion:function(){
			var U, S, M, g, temp;
			U="0";
			if(navigator.plugins&&navigator.plugins.length){
				for(g=0;g<navigator.plugins.length;g++){
					S=navigator.plugins[g];
					M=S.name.match(/quicktime\D*([\.\d]*)/i);
					if(M&&M[1]){
						U=M[1];
					}
				}
			}else{
				ieQTVersion=null;
				execScript("on error resume next: ieQTVersion = CreateObject(\"QuickTimeCheckObject.QuickTimeCheck.1\").QuickTimeVersion","VBScript");
				if(ieQTVersion){
					temp = "";
					U=(ieQTVersion).toString(16)/1000000+"";//(ieQTVersion>>24).toString(16);
					temp += parseInt(U)+".";
					temp += ((parseFloat(U)-parseInt(U))*1000)/100+"";

					//alert(temp);
					U = temp;
				}
			}
			return U;
		},
		isQTCompatible:function(g,j){
			function M(w,R){
				var i, V;
				i=parseInt(w[0],10);
				if(isNaN(i)){
					i=0;
				}
				V=parseInt(R[0],10);
				if(isNaN(V)){
					V=0;
				}
				if(i===V){
					if(w.length>1){
						return M(w.slice(1),R.slice(1));
					}else{
						return true;
					}
				}else{
					if(i<V){
						return true;
					}else{
						return false;
					}
				}
			}
			var S, U;
			S=g.split(/\./);
			U=j?j.split(/\./):this.getQTVersion().split(/\./);
			return M(S,U);
		},
		isValidQTAvailable:function(U){
			return this.isQTInstalled()&&this.isQTCompatible(U);
		}
	};
},


ImagePreLoadingForIE: function() {
	// Full list, wityh some image that are not usefull anymore
	// var listImage = new Array( 'ow_bouton_play', 'ow_bouton_pause', 'ow_bouton_play_pause', 'ow_bouton_fast_rewind', 'ow_bouton_fast_forward', 'ow_bouton_step_rewind', 'ow_bouton_step_forward', 'ow_bouton_go_to_end', 'ow_bouton_go_to_beginning', 'ow_bouton_fullscreen_open', 'ow_bouton_fullscreen_close', 'ow_bouton_mute_sound', 'ow_bouton_max_sound', 'ow_bouton_help', 'ow_bouton_logo_player', 'ow_logo_quicktime', 'ow_background_jog_slider', 'ow_image_jog_slider', 'ow_background_sound_slider', 'ow_bouton_beg_selection', 'ow_bouton_end_selection', 'ow_bouton_save_selection', 'ow_bouton_new_selection', 'ow_bouton_annotate_selection');
	// light list, with only the lost important images
	// alert('about to preload');
	var listImage, imageArray, x;
	listImage = new Array( 'ow_bouton_play', 'ow_bouton_pause', 'ow_bouton_play_pause', 'ow_bouton_fast_rewind', 'ow_bouton_fast_forward', 'ow_bouton_step_rewind', 'ow_bouton_step_forward', 'ow_bouton_go_to_end', 'ow_bouton_go_to_beginning', 'ow_bouton_fullscreen_open', 'ow_bouton_fullscreen_close', 'ow_bouton_help', 'ow_bouton_logo_player', 'ow_logo_quicktime', 'ow_background_jog_slider', 'ow_image_jog_slider', 'ow_background_sound_slider', 'ow_bouton_beg_selection', 'ow_bouton_end_selection', 'ow_bouton_save_selection', 'ow_bouton_new_selection', 'ow_bouton_annotate_selection');
	imageArray = new Array();
	
	for (x = 0; x < listImage.length; x++)	{
		imageArray[x] =  new Image;
		imageArray[x].src =  this.movie_options.imageRootURL + this.movie_options.images[ listImage[x] ] ;
	}
	listImage = new Array( 'ow_bouton_fast_rewind', 'ow_bouton_fast_forward', 'ow_bouton_step_rewind', 'ow_bouton_step_forward');
	for (x = 0; x < listImage.length; x++)	{
		imageArray[x] =  new Image;
		imageArray[x].src =  this.movie_options.imageRootURL + this.movie_options.images_pressed[ listImage[x] ] ;
	}
	
},

/************************************************************************/
/*	PRESETS 															*/
/*			PRESETS : Options For some specific web site				*/
/*															PRESETS		*/
/************************************************************************/

movie_options_LNR: {
	controller_panel_width	: 640	,
	controller_panel_height	: 80 	, 
	timecode_lag			: null	, 
	timecode_lag_in_second	: 0		,
	timecode_with_frame		: false	,	// if true, the frame are displayed
	config_help				: false	,	// to get the help instead of the player
	help					: false	, 	//	shortcut for config_help
	name					: 'movie1',
	autoplay				: true	,
	fullscreen				: false	,
	popUpFullscreen			: true	, 
	urlOfFullscreenPage		: 'ow_template_fullscreen.html'	,	// PHP: document.location.href.gsub(/[#]/, '') + '&FS=on',
	onMovieFinished			: null	,	// Not yet implemented
	onMovieFullScreen		: null	,	
	urlOfReplacementImage	: 'ow_images_LNR/videoPlayer/Play.gif'	,
	urlOfEndImage			: 'ow_images_LNR/videoPlayer/Play.gif'	,
	imageRootURL			: 'ow_images_LNR/',	// location of the images 
	typeMime				: 'video/quicktime',
	language				: 'fr'	,	// 'en' or 'fr' to get tooltips in French or English
	debug_mode				: false	,
	expectedQTversion		: '7.3'	,
	quicktimeDetection		: false	,	
	code_controller 		: '<!-- Controller Design -->								 '	+
		'	<table border="0" cellpadding="0" cellspacing="0" id="tableSlider">				 '	+
		'		<!-- First Line +++++++++++++++++++++++++++++++++++++++++++++++     -->		 '	+
		'		<tr id="ligne-one">															 '	+
		'			<!-- Progress Bar +++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
		'			<td id="ow_id_progress_slider" class="controller" colspan="4">	</td>	 '	+
		'			<!-- TimeCode +++++++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
		'			<td id="controller-timecode" 											 '	+
		'			class="controller"><p id="ow_id_timecode">--:--:--</p></td>				 '	+
		'		</tr>																		 '	+
		'		<tr id="ligne-two">															 '	+
		'			<!-- Play  Pause la video +++++++++++++++++++++++++++++++++ 	-->		 '	+
		'			<td id="navigation-play-pause" class="controller">						 '	+
		'				<a id="ow_bouton_play"><img/></a>									 '	+
		'				<a id="ow_bouton_pause"><img/></a>									 '	+
		'			</td>																	 '	+
		'			<!-- Avance Retour Rapide +++++++++++++++++++++++++++++++++ 	-->		 '	+
		'			<td id="navigation-fast">												 '	+
		'				<a id="ow_bouton_fast_rewind"><img/></a> 							 '	+
		'				<a id="ow_bouton_fast_forward"><img/></a>							 '	+
		'			</td>																	 '	+
		'			<!-- Full Screen  +++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
		'			<td id="navigation-zone-full-screen" class="controller">				 '	+
		'				<a id="ow_bouton_fullscreen"><img/></a>								 '	+
		'				<a id="ow_bouton_mute_sound"><img/></a>								 '	+
		'			</td>																	 '	+
		'			<td id="empty"></td>													 '	+
		'			<!-- Sound  +++++++++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
		'			<td id="ow_id_sound_slider">	</td>									 '	+
		'		</tr>																		 '	+
		'	</table>',
	code_panel_end 			: '<a id="ow_image_end_restart_video"><img></a><br><a id="ow_bouton_play_again"><img></a>',
	code_panel_end_FS		: '<a id="ow_image_end_restart_video"><img></a><br><a id="ow_bouton_fullscreen_end"><img/></a> '	+
		'							<a id="ow_bouton_play_again"><img></a>',
	code_end_FS_movie_panel	: '<a id="ow_image_wentFS_restart_video"><img></a><br><a id="ow_bouton_play_again_afterFS"><img></a>',					
	images					: {
		'ow_bouton_play'				: 'Play.gif',
		'ow_bouton_pause'				: 'Pause.gif',
		'ow_bouton_play_pause'			: 'Play.gif',
		'ow_bouton_play_again'			: 'Play.gif',
		'ow_bouton_fast_rewind'			: 'FastRewind.gif',
		'ow_bouton_fast_forward'		: 'FastForward.gif',
		'ow_bouton_fullscreen_open'		: 'CloseFS.gif',
		'ow_bouton_fullscreen_close'	: 'CloseFS.gif',
		'ow_bouton_mute_sound'			: 'BTsonOff.png',				
		'ow_bouton_max_sound'			: 'BTsonOff.png',
		'ow_logo_quicktime'				: 'logo_qtlogo.gif',	
		'ow_background_sound_slider'	: 'Sound.gif'		
	},
	tooltips_fr				: {
		'ow_id_timecode' 				: 'Timecode (HH:mm:ss)',
		'ow_id_timecodeLong' 			: 'Timecode (HH:mm:ss.frame)',
		'ow_id_sound_slider'			: 'Volume sonore',
		'ow_id_progress_slider'			: 'Barre de progression',
		'ow_id_jog_slider'				: 'Jog Shuttle',
		'ow_bouton_play' 				: 'Lance la vidéo',
		'ow_bouton_pause' 				: 'Pause la vidéo',
		'ow_bouton_play_pause' 			: 'Lance ou Pause la vidéo',
		'ow_bouton_play_again'			: 'Relance la vidéo',
		'ow_bouton_fast_rewind' 		: 'Retour Rapide',
		'ow_bouton_fast_forward' 		: 'Avance Rapide',
		'ow_bouton_step_rewind'			: 'Reculer d\'une image',
		'ow_bouton_step_forward'		: 'Avancer d\'une image',
		'ow_bouton_go_to_beginning'		: 'Retourner au début du film',
		'ow_bouton_go_to_end'			: 'Aller à la fin',
		'ow_bouton_fullscreen_open'		: 'Ouvre en plein écran',
		'ow_bouton_fullscreen_close'	: 'Ferme la fenêtre',
		'ow_bouton_mute_sound' 			: 'Coupe le son',
		'ow_bouton_max_sound' 			: 'Son au maximum',
		'ow_bouton_logo_player'			: 'OraoWeb : Player Quicktime + Javascript ',	
		'ow_selection_start_handle'		: 'Début de l\'extrait',
		'ow_selection_end_handle'		: 'Fin de l\'extrait',
		'ow_bouton_help'				: 'Afficher l\'écran d\'aide',

		'mes_help_title'				: 'Aide',
		'mes_help'						: '<h4>Pour créer vos propres extraits</h4><p>- sélectionnez le début de l\'extrait : cliquez sur ow_bouton_beg_selection<br>- sélectionnez la fin de l\'extrait : cliquez sur ow_bouton_end_selection<br>- saisissez votre titre<br>- sauvegardez votre extrait : cliquez sur ow_bouton_save_selection</p><h4>Pour créer d\'autres extraits, cliquez sur ow_bouton_new_selection</h4><h4>Pour annoter vos extraits, cliquez sur ow_bouton_annotate_selection</h4><h5>[ retour au visionnage ]</h5>',
		'mes_copyright_title'			: 'Orao : Player Quicktime + Javascript ',
		'mes_copyright'					: 'Orao : Player QuickTime. Ver.'+ OW_OraoWeb_version +' ('+OW_OraoWeb_version_release_date+'). Copyright Opsomai',

		'mes_plugin_not_yet_ready'		: 'Il semble que votre navigateur n\'ai pas réussit à se connecter au plug-in video. Ceci peut être du à un ordinateur relativement lent. Le navigateur va tenter une nouvelle connexion 3 secondes apres que vous ayez fermé cette alerte. Dans le doute, vous pouvez vérifier que le plug-in quicktime est correctement installé et autorisé.',
		'mes_quicktime_not_up_to_date'	: '<h4>Votre version de QuickTime n\'est pas &agrave; jour</h4><h5>La version attendue est au moins la version : <span id="ow_quicktime_expected_version"></span></h5> <h5>Pour installer une version plus récente de QuickTime <a href="http://www.apple.com/fr/quicktime/download/">téléchargez l\'installeur sur le site d\'Apple (suivez ce lien)</a></h5>',
		'mes_quicktime_not_available'	: '<h4>Vous n\'avez pas QuickTime install&eacute;</h4> <h5>Pour installer QuickTime <a href="http://www.apple.com/fr/quicktime/download/">téléchargez l\'installeur sur le site d\'Apple (suivez ce lien)</a></h5><h5>Si QuickTime est correctement install&eacute; sur votre machine et que ce message apparait quand m&ecirc;me, <a href="mailto:orao@opsomai.com">n\'hésitez pas à nous contacter</a> avec une description de votre configuration (nom et version de votre navigateur, système d\'exploitation et version de Quicktime installée)</h5>'
	},
	tooltips_en				: {
		'ow_id_timecode' 				: 'Timecode (HH:mm:ss)',
		'ow_id_timecodeLong' 			: 'Timecode (HH:mm:ss.frame)',
		'ow_id_sound_slider'			: 'Sound volume',
		'ow_id_progress_slider'			: 'Progress bar',
		'ow_id_jog_slider'				: 'Jog Shuttle',
		'ow_bouton_play' 				: 'Play the video',
		'ow_bouton_pause' 				: 'Stop the video',
		'ow_bouton_play_pause' 			: 'Play or Stop the video (switch)',
		'ow_bouton_play_again'			: 'Restart the video',
		'ow_bouton_fast_rewind' 		: 'Fast rewind',
		'ow_bouton_fast_forward' 		: 'Fast forward',
		'ow_bouton_step_rewind'			: 'Back up one image',
		'ow_bouton_step_forward'		: 'Forward by one image',
		'ow_bouton_go_to_beginning'		: 'Go to the beginning',
		'ow_bouton_go_to_end'			: 'Go to the end',
		'ow_bouton_fullscreen_open'		: 'Switch to FullScreen',
		'ow_bouton_fullscreen_close'	: 'Close the fullscreen window',
		'ow_bouton_mute_sound' 			: 'Sound off',
		'ow_bouton_max_sound' 			: 'Max the sound',
		'ow_bouton_logo_player'			: 'OraoWeb : QuickTime + Javascript Player',	
		'ow_selection_start_handle'		: 'Extract beginning',
		'ow_selection_end_handle'		: 'Extract end',
		'ow_bouton_help'				: 'Show help screen',

		'mes_help_title'				: 'Help',
		'mes_help'						: '<h4>To create your own extract:</h4><p>- select the beginning of the extract: click on ow_bouton_beg_selection<br>- select the end of the extract: click on ow_bouton_end_selection<br>- key in your title<br>- save your extract: click on ow_bouton_save_selection</p><h4>To create another extract: click on ow_bouton_new_selection</h4><h4>To annotate your extract: click on ow_bouton_annotate_selection</h4><h5>[ return to viewing ]</h5>',
		'mes_copyright_title'			: 'OraoWeb : Quicktime + Javascript Player',
		'mes_copyright'					: 'OraoWeb : QuickTime Player. Ver.'+ OW_OraoWeb_version +' ('+OW_OraoWeb_version_release_date+'). Copyright Opsomai',

		'mes_plugin_not_yet_ready'		: 'It looks like the video player cannot reach the video plug-in. This can be due to a slow computer. It will try again 3s after you close this alert message. Please check that QuickTime plug-in is installed and authorised.',
		'mes_quicktime_not_up_to_date'	: '<h4>Your QuickTime is not up to date</h4><h5>The expected version is at least : <span id="ow_quicktime_expected_version"></span></h5>  <h5>To install a recent version of QuickTime, please <a href="http://www.apple.com/quicktime/download/">visit the Apple web site and follow the procedure.</a><h5>',
		'mes_quicktime_not_available'	: '<h4>QuickTime is not installed on your machine</h4> <h5>To install this tool, please <a href="http://www.apple.com/quicktime/download/">visit the Apple web site and follow the procedure.</a><h5><h5>If QuickTime is indeed intalled on your machine, please <a href="mailto:orao@opsomai.com">send us an email</a> with a description of your configuration (name and version of your web browser and Operating System, version of installed QuickTime)</h5>'
	}
},


//  ===========================================================================
//  Preset  OPSIS : defaut pour les clients Opsomai opsomai OPSOMAI

movie_options_OPSIS: {
	width					: 320	,
	height					: 240	,
	controller_panel_width	: 320	,
	controller_panel_height	: 110 	, 
	free_vertical_height	: 118	,
	window_position_x		: 50	,
	window_position_y		: 50	,
	window_default_width	: 400	,
	window_default_height	: 350	,
	timecode_with_frame		: true	,	// if true, the frame are displayed
	autoplay				: true	,
	advance_jog_shuttle		: false	,
	urlOfFullscreenPage		: 'ow_template_fullscreen_OPSIS.html'	,	// PHP: document.location.href.gsub(/[#]/, '') + '&FS=on',
	urlOfReplacementImage	: 'ow_images_OPSIS/videoPlayer/Play.gif'	,
	urlOfEndImage			: 'ow_images_OPSIS/videoPlayer/Play.gif'	,
	imageRootURL			: 'ow_images_OPSIS/',	// location of the images 
	doNothingOnMovieFinished: true	,
	popUpFullscreen			: false	, 
	sound_handle_variable	: true	,
	debug_mode				: false	,
	sound_slider_height		: 11	,
	sound_slider_width		: 51	,
	position_slider_width	: 300	,
	selection_adjust_cursor	: 5		,
	language				: 'fr'	,	// 'en' or 'fr' to get tooltips in French or English
	expectedQTversion		: '7.3'	,	// quicktime_66 pour du h264, QuickTime 7.2.1  pour les event et QT 7.3.1 pour arret du Flash
	quicktimeDetection		: false	,	
	code_controller 		: '<!-- Controller Design -->								 '	+
	'	<table border="0" cellpadding="0" cellspacing="0" id="tableSlider">				 '	+
	'		<!-- First Line +++++++++++++++++++++++++++++++++++++++++++++++     -->		 '	+
	'		<tr id="ligne-one">															 '	+
	'			<!-- Progress Bar +++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<td id="ow_id_progress_slider" class="controller" colspan="3">	</td>	 '	+
	'		</tr>																		 '	+
	'		<tr id="ligne-jog">															 '	+
	'			<!-- Jog Shuttle Bar +++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<td id="ow_id_jog_slider" class="controller" colspan="3">	</td>	 '	+
	'		</tr>																		 '	+
	'		<tr id="ligne-one-bis">														 '	+
	'			<!-- TimeCode +++++++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<td id="controller-help"><a id="ow_bouton_help"><img/></a></td>			 '	+
	'			<td id="controller-timecode"								 '	+
	'			class="controller"><p id="ow_id_timecode">--:--:--</p></td>				 '	+
	'			<td id="controller-jog"><p id="ow_id_jog_value"> </p></td>			 '	+
	'		</tr>																		 '	+
	'		<tr id="ligne-two">															 '	+
	'			<!-- Sound  +++++++++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<td id="ow_id_sound_slider">	</td>									 '	+
	'			<!--  Retour Rapide +++++++++++++++++++++++++++++++++ 	-->				 '	+
	'			<td id="navigation" colspan="2">												 '	+
	'				<a id="ow_bouton_go_to_beginning"><img/></a><a id="ow_bouton_fast_rewind"><img/></a><a id="ow_bouton_step_rewind"><img/></a><a id="ow_bouton_play_pause"><img/></a><a id="ow_bouton_step_forward"><img/></a><a id="ow_bouton_fast_forward"><img/></a><a id="ow_bouton_go_to_end"><img/></a><a id="ow_bouton_fullscreen"><img/></a>								 '	+
	'			</td>																	 '	+
	'		</tr>																		 '	+
	'	</table>',
	images					: {
		'ow_bouton_play'				: 'boutons/b_play_petit.gif'			,
		'ow_bouton_pause'				: 'boutons/b_pause_petit.gif'			,
		'ow_bouton_play_pause'			: 'boutons/b_play_petit.gif'			,
		'ow_bouton_play_again'			: 'boutons/b_play_petit.gif'			,
		'ow_bouton_fast_rewind'			: 'boutons/b_retour_rapide_petit.gif'	,
		'ow_bouton_fast_forward'		: 'boutons/b_avance_rapide_petit.gif'	,
		'ow_bouton_step_rewind'			: 'boutons/b_image_avant_petit.gif'		,
		'ow_bouton_step_forward'		: 'boutons/b_image_apres_petit.gif'		,
		'ow_bouton_go_to_end'			: 'boutons/b_aller_fin_petit.gif'		,
		'ow_bouton_go_to_beginning'		: 'boutons/b_aller_debut_petit.gif'		,
		'ow_bouton_fullscreen_open'		: 'boutons/b_plein_ecran_petit.gif'		,
		'ow_bouton_fullscreen_close'	: 'boutons/b_plein_ecran_petit.gif'		,
		'ow_bouton_mute_sound'			: 'boutons/b_hp_droit_petit.png'		,
		'ow_bouton_max_sound'			: 'boutons/b_hp_droit_petit.png'		,
		'ow_bouton_help'				: 'boutons/b_aide_petit.gif'			,
		'ow_bouton_logo_player'			: 'logo.gif'							,
		'ow_logo_quicktime'				: 'logo_qtlogo.gif'						,
		// 'ow_image_sound_slider'			: 'volume_slider/b_curseur_volume_petit.png',	
		'ow_background_jog_slider'		: 'jogshuttle/barre_jogshuttle.png'		,
		'ow_image_jog_slider'			: 'jogshuttle/b_curseur_jogshuttle_petit.gif'	,
		'ow_background_sound_slider'	: 'volume_slider/sound_bg_petit.gif'	,
		'ow_bouton_beg_selection'		: 'boutons/b_definir_debut_petit.gif'	,	
		'ow_bouton_end_selection'		: 'boutons/b_definir_fin_petit.gif'		,	
		'ow_bouton_save_selection'		: 'boutons/b_disquette_petit.gif'		,	
		'ow_bouton_new_selection'		: 'boutons/b_nouv_chap_petit.gif'		,	
		'ow_bouton_annotate_selection'	: 'boutons/b_annoter_petit.gif'			
	}	,
	images_pressed					: {
		'ow_bouton_play'				: 'boutons/b_play_petit.gif'			,
		'ow_bouton_pause'				: 'boutons/b_pause_petit.gif'			,
		'ow_bouton_play_pause'			: 'boutons/b_play_petit.gif'			,
		'ow_bouton_play_again'			: 'boutons/b_play_petit.gif'			,
		'ow_bouton_fast_rewind'			: 'boutons_pressed/b_retour_rapide_petit.gif'	,
		'ow_bouton_fast_forward'		: 'boutons_pressed/b_avance_rapide_petit.gif'	,
		'ow_bouton_step_rewind'			: 'boutons_pressed/b_image_avant_petit.gif'		,
		'ow_bouton_step_forward'		: 'boutons_pressed/b_image_apres_petit.gif'		,
		'ow_bouton_go_to_end'			: 'boutons/b_aller_fin_petit.gif'		,
		'ow_bouton_go_to_beginning'		: 'boutons/b_aller_debut_petit.gif'		,
		'ow_bouton_fullscreen_open'		: 'boutons/b_plein_ecran_petit.gif'		,
		'ow_bouton_fullscreen_close'	: 'boutons/b_plein_ecran_petit.gif'		,
		'ow_bouton_mute_sound'			: 'boutons/b_hp_droit_petit.png'		,
		'ow_bouton_max_sound'			: 'boutons/b_hp_droit_petit.png'		,
		'ow_bouton_help'				: 'boutons/b_aide_petit.gif'			,
		'ow_bouton_logo_player'			: 'logo.gif'							,
		'ow_logo_quicktime'				: 'logo_qtlogo.gif'						,
		// 'ow_image_sound_slider'			: 'volume_slider/b_curseur_volume_petit.png',	
		'ow_background_jog_slider'		: 'jogshuttle/barre_jogshuttle.png'		,
		'ow_image_jog_slider'			: 'jogshuttle/b_curseur_jogshuttle_petit.gif'	,
		'ow_background_sound_slider'	: 'volume_slider/sound_bg_petit.gif'	,
		'ow_bouton_beg_selection'		: 'boutons/b_definir_debut_petit.gif'	,	
		'ow_bouton_end_selection'		: 'boutons/b_definir_fin_petit.gif'		,	
		'ow_bouton_save_selection'		: 'boutons/b_disquette_petit.gif'		,	
		'ow_bouton_new_selection'		: 'boutons/b_nouv_chap_petit.gif'		,	
		'ow_bouton_annotate_selection'	: 'boutons/b_annoter_petit.gif'			
	},
	tooltips_fr				: {
		'ow_id_timecode' 				: 'Time Code (HH:mm:ss)',
		'ow_id_timecodeLong' 			: 'Time Code (HH:mm:ss.frame)',
		'ow_id_sound_slider'			: 'Volume sonore',
		'ow_id_progress_slider'			: 'Barre de progression',
		'ow_id_jog_slider'				: 'Jog Shuttle',
		'ow_bouton_play' 				: 'Lecture',
		'ow_bouton_pause' 				: 'Pause',
		'ow_bouton_play_pause' 			: 'Lecture ou Pause (suivant contexte)',
		'ow_bouton_play_again'			: 'Relance la visionneuse',
		'ow_bouton_fast_rewind' 		: 'Retour rapide',
		'ow_bouton_fast_forward' 		: 'Avance rapide',
		'ow_bouton_step_rewind'			: 'Reculer d\'une image',
		'ow_bouton_step_forward'		: 'Avancer d\'une image',
		'ow_bouton_go_to_beginning'		: 'Retourner au début du film',
		'ow_bouton_go_to_end'			: 'Aller à la fin',
		'ow_bouton_fullscreen_open'		: 'Passer en plein écran',
		'ow_bouton_fullscreen_close'	: 'Revenir à la taille normale',
		'ow_bouton_mute_sound' 			: 'Coupe le son',
		'ow_bouton_max_sound' 			: 'Son au maximum',
		'ow_bouton_left_sound'			: 'Entendre uniquement la piste gauche du son'	,
		'ow_bouton_right_sound'			: 'Entendre uniquement la piste droite du son'	,
		'ow_bouton_logo_player'			: 'OraoWeb : Player Quicktime + Javascript ',	
		'ow_selection_start_handle'		: 'Début de l\'extrait',
		'ow_selection_end_handle'		: 'Fin de l\'extrait',
		'ow_bouton_help'				: 'Afficher l\'écran d\'aide',

		'mes_help_title'				: 'Aide',
		'mes_help'						: '<h4>Pour créer vos propres extraits</h4><p>- créez un nouvel extrait : cliquez sur... ow_bouton_new_selection<br/>- si nécessaire, modifiez la position de la tête de lecture,<br/> puis ajustez le début de l\'extrait : cliquez sur... ow_bouton_beg_selection<br/>- modifiez la position de la tête de lecture,<br/> puis sélectionnez la fin de l\'extrait : cliquez sur... ow_bouton_end_selection<br/>- saisissez votre titre<br/>- sauvegardez votre extrait : cliquez sur... ow_bouton_save_selection</p><h5>[ retour au visionnage ]</h5>',
		'mes_copyright_title'			: 'Orao : Player Quicktime + Javascript ',
		'mes_copyright'					: 'Orao : Player QuickTime. Ver.'+ OW_OraoWeb_version +' ('+OW_OraoWeb_version_release_date+'). Copyright Opsomai',

		'mes_plugin_not_yet_ready'		: 'Il semble que votre navigateur n\'ai pas réussit à se connecter au plug-in video. Ceci peut être du à un ordinateur relativement lent. Le navigateur va tenter une nouvelle connexion 3 secondes apres que vous ayez fermé cette alerte. Dans le doute, vous pouvez vérifier que le plug-in quicktime est correctement installé et autorisé.',
		'mes_quicktime_not_up_to_date'	: '<h4>Votre version de QuickTime n\'est pas &agrave; jour</h4><h5>La version attendue est au moins la version : <span id="ow_quicktime_expected_version"></span></h5> <h5>Pour installer une version plus récente de QuickTime <a href="http://www.apple.com/fr/quicktime/download/">téléchargez l\'installeur sur le site d\'Apple (suivez ce lien)</a></h5>',
		'mes_quicktime_not_available'	: '<h4>Vous n\'avez pas QuickTime install&eacute;</h4> <h5>Pour installer QuickTime <a href="http://www.apple.com/fr/quicktime/download/">téléchargez l\'installeur sur le site d\'Apple (suivez ce lien)</a></h5><h5>Si QuickTime est correctement install&eacute; sur votre machine et que ce message apparait quand m&ecirc;me, <a href="mailto:orao@opsomai.com">n\'hésitez pas à nous contacter</a> avec une description de votre configuration (nom et version de votre navigateur, système d\'exploitation et version de Quicktime installée)</h5>',
		'mes_flash_not_available'	: '<h4>Adobe Flash n\'est pas installé ou nécessite une mise à jour</h4> <h5>Pour installer Flash (ou effectuer une mise à jour) <a href="http://www.macromedia.com/go/getflash/">téléchargez l\'installeur sur le site d\'Adobe (suivez ce lien)</a></h5><h5>Si Flash est correctement install&eacute; sur votre machine et que ce message apparait quand m&ecirc;me, <a href="mailto:orao@opsomai.com">n\'hésitez pas à nous contacter</a> avec une description de votre configuration (nom et version de votre navigateur, système d\'exploitation et version de Flash installée)</h5>'
	},
	tooltips_en				: {
		'ow_id_timecode' 				: 'Time Code (HH:mm:ss)',
		'ow_id_timecodeLong' 			: 'Time Code (HH:mm:ss.frame)',
		'ow_id_sound_slider'			: 'Sound volume',
		'ow_id_progress_slider'			: 'Progress bar',
		'ow_id_jog_slider'				: 'Jog Shuttle',
		'ow_bouton_play' 				: 'Play',
		'ow_bouton_pause' 				: 'Pause',
		'ow_bouton_play_pause' 			: 'Play or Pause (switch)',
		'ow_bouton_play_again'			: 'Restart the player',
		'ow_bouton_fast_rewind' 		: 'Fast rewind',
		'ow_bouton_fast_forward' 		: 'Fast forward',
		'ow_bouton_step_rewind'			: 'Back up one image',
		'ow_bouton_step_forward'		: 'Forward by one image',
		'ow_bouton_go_to_beginning'		: 'Go to the beginning',
		'ow_bouton_go_to_end'			: 'Go to the end',
		'ow_bouton_fullscreen_open'		: 'Show full screen',
		'ow_bouton_fullscreen_close'	: 'Exit full screen',
		'ow_bouton_mute_sound' 			: 'Sound off',
		'ow_bouton_max_sound' 			: 'Max the sound',
		'ow_bouton_left_sound'			: 'Get only the left side of the sound'	,
		'ow_bouton_right_sound'			: 'Get only the right side of the sound'	,
		'ow_bouton_logo_player'			: 'OraoWeb : QuickTime + Javascript Player',
		'ow_selection_start_handle'		: 'Extract beginning',
		'ow_selection_end_handle'		: 'Extract end',
		'ow_bouton_help'				: 'Show help screen',

		'mes_help_title'				: 'Help',
		'mes_help'						: '<h4>To create your own extract:</h4><p>- initialize a new extract: click on ow_bouton_new_selection<br/>- if necessary, adjust the playhead to the expected beginning,<br/> then select the beginning of the extract: click on ow_bouton_beg_selection<br/>- adjust the playhead, then select the end of the extract: click on ow_bouton_end_selection<br/>- key in your title<br/>- save your extract: click on ow_bouton_save_selection</p><h5>[ return to viewing ]</h5>',
		'mes_copyright_title'			: 'Orao : Quicktime + Javascript Player',
		'mes_copyright'					: 'Orao : QuickTime Player. Ver.'+ OW_OraoWeb_version +' ('+OW_OraoWeb_version_release_date+'). Copyright Opsomai',

		'mes_plugin_not_yet_ready'		: 'It looks like the video player cannot reach the video plug-in. This can be due to a slow computer. It will try again 3s after you close this alert message. Please check that QuickTime plug-in is installed and authorised.',
		'mes_quicktime_not_up_to_date'	: '<h4>Your QuickTime is not up to date</h4><h5>The expected version is at least : <span id="ow_quicktime_expected_version"></span></h5>  <h5>To install a recent version of QuickTime, please <a href="http://www.apple.com/quicktime/download/">visit the Apple web site and follow the procedure.</a><h5>',
		'mes_quicktime_not_available'	: '<h4>QuickTime is not installed on your machine</h4> <h5>To install this tool, please <a href="http://www.apple.com/quicktime/download/">visit the Apple web site and follow the procedure.</a><h5><h5>If QuickTime is indeed intalled on your machine, please <a href="mailto:orao@opsomai.com">send us an email</a> with a description of your configuration (name and version of your web browser and Operating System, version of installed QuickTime)</h5>',
		'mes_flash_not_available'	: '<h4>Adobe Flash is not installed on your machine or is not up to date</h4> <h5>To install, or update, this tool, please<a href="http://www.macromedia.com/go/getflash/">visit the Adobe web site and follow the procedure.</a></h5><h5>If Flash is indeed intalled on your machine, please <a href="mailto:orao@opsomai.com">send us an email</a> with a description of your configuration (name and version of your web browser and Operating System, version of installed Flash)</h5>'
	}

},

//  ===========================================================================
//  Preset  OPSIS MINI mini : miniplayer pour les clients Opsomai opsomai OPSOMAI

movie_options_OPSIS_MINI: {
	width					: 320	,
	height					: 240	,
	position_slider_width	: 300	,
	selection_adjust_left	: 0		,
	selection_adjust_cursor	: 1		,
	selection_adjust_right	: 4		,
	timecode_with_frame		: true	,
	
	autoplay				: false	,
	urlOfReplacementImage	: 'design/images/ow_images_OPSIS_MINI/videoPlayer/Play.gif'	,
	urlOfEndImage			: 'design/images/ow_images_OPSIS_MINI/videoPlayer/Play.gif'	,
	imageRootURL			: 'design/images/ow_images_OPSIS_MINI/',

	doNothingOnMovieFinished: true	,
	popUpFullscreen			: false	, 
	sound_handle_variable	: false	,
	debug_mode				: false	,
	quicktimeDetection		: false	,

	sound_slider_height		: 11	,
	sound_slider_width		: 51	,
	language				: 'fr'	,
	expectedQTversion		: '7.3'	,

	controller_panel_width	: 320	,
	controller_panel_height	: 110 	, 
	free_vertical_height	: 118	,
	window_position_x		: 50	,
	window_position_y		: 50	,
	window_default_width	: 570	,
	window_default_height	: 395	,
	code_controller 		: '<!-- Controller Design -->								 '	+
	'	<table border="0" cellpadding="0" cellspacing="0" id="tableSlider">				 '	+
	'		<!-- First Line +++++++++++++++++++++++++++++++++++++++++++++++     -->		 '	+
	'		<tr id="ligne-one">															 '	+
	'			<!-- Progress Bar +++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<td id="ow_id_progress_slider" class="controller" colspan="2">	</td>	 '	+
	'		</tr>																		 '	+
	'		<tr id="ligne-jog">															 '	+
	'			<!-- Jog Shuttle Bar +++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<td id="ow_id_jog_slider" class="controller" colspan="2">	</td>	 '	+
	'		</tr>	 '	+
	'		<tr id="ligne-one-bis">														 '	+
	'			<!-- TimeCode +++++++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<td id="controller-timecode"								 '	+
	'			class="controller"><p id="ow_id_timecode">--:--:--</p></td>				 '	+
	'			<td id="controller-jog"><p id="ow_id_jog_value"> </p></td>			 '	+
	'		</tr>													 '	+
	'		<tr id="ligne-two">															 '	+
	'			<!--  Retour Rapide +++++++++++++++++++++++++++++++++ 	-->				 '	+
	'			<td id="navigation" >													 '	+
	'				<a id="ow_bouton_go_to_beginning"><img/></a> 						 '	+
	'				<a id="ow_bouton_fast_rewind"><img/></a> 							 '	+
	'				<a id="ow_bouton_step_rewind"><img/></a> 							 '	+
	'				<a id="ow_bouton_play_pause"><img/></a>								 '	+
	'				<a id="ow_bouton_step_forward"><img/></a>							 '	+
	'				<a id="ow_bouton_fast_forward"><img/></a>							 '	+
	'				<a id="ow_bouton_go_to_end"><img/></a> 								 '	+
	'			</td>																	 '	+
	'			<!-- Sound  +++++++++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<td id="ow_id_sound_slider">	</td>									 '	+
	'		</tr>																		 '	+
	'	</table>',
	images					: {
		'ow_bouton_play'				: 'boutons/b_play_petit.gif'				,
		'ow_bouton_pause'				: 'boutons/b_pause_petit.gif'				,
		'ow_bouton_play_pause'			: 'boutons/b_play_petit.gif'				,
		'ow_bouton_play_again'			: 'boutons/b_play_petit.gif'				,
		'ow_bouton_fast_rewind'			: 'boutons/b_retour_rapide_petit.gif'		,
		'ow_bouton_fast_forward'		: 'boutons/b_avance_rapide_petit.gif'		,
		'ow_bouton_step_rewind'			: 'boutons/b_image_avant_petit.gif'			,
		'ow_bouton_step_forward'		: 'boutons/b_image_apres_petit.gif'			,
		'ow_bouton_go_to_end'			: 'boutons/b_aller_fin_petit.gif'			,
		'ow_bouton_go_to_beginning'		: 'boutons/b_aller_debut_petit.gif'			,
		'ow_bouton_mute_sound'			: 'boutons/b_hp_droit_petit.png'			,
		'ow_bouton_max_sound'			: 'boutons/b_hp_droit_petit.png'			,
		'ow_bouton_help'				: 'boutons/b_aide_petit.gif'				,
		'ow_bouton_logo_player'			: 'logo.gif'								,
		'ow_logo_quicktime'				: 'logo_qtlogo.gif'							,
		'ow_background_jog_slider'		: 'jogshuttle/barre_jogshuttle.png'		,
		'ow_image_jog_slider'			: 'jogshuttle/b_curseur_jogshuttle_petit.gif'	,
		'ow_image_sound_slider'			: 'volume_slider/b_curseur_volume_petit.gif',
		'ow_background_position_slider'	: 'timeline/fond_metre.gif'					,
		'ow_background_sound_slider'	: 'volume_slider/sound_bg_petit.gif'
	},
	images_pressed			: {
		'ow_bouton_play'				: 'boutons/b_play_petit.gif'				,
		'ow_bouton_pause'				: 'boutons/b_pause_petit.gif'				,
		'ow_bouton_play_pause'			: 'boutons/b_play_petit.gif'				,
		'ow_bouton_play_again'			: 'boutons/b_play_petit.gif'				,
		'ow_bouton_fast_rewind'			: 'boutons_pressed/b_retour_rapide_petit.gif'		,
		'ow_bouton_fast_forward'		: 'boutons_pressed/b_avance_rapide_petit.gif'		,
		'ow_bouton_step_rewind'			: 'boutons_pressed/b_image_avant_petit.gif'			,
		'ow_bouton_step_forward'		: 'boutons_pressed/b_image_apres_petit.gif'			,
		'ow_bouton_go_to_end'			: 'boutons/b_aller_fin_petit.gif'			,
		'ow_bouton_go_to_beginning'		: 'boutons/b_aller_debut_petit.gif'			,
		'ow_bouton_mute_sound'			: 'boutons/b_hp_droit_petit.png'			,
		'ow_bouton_max_sound'			: 'boutons/b_hp_droit_petit.png'			,
		'ow_bouton_help'				: 'boutons/b_aide_petit.gif'				,
		'ow_bouton_logo_player'			: 'logo.gif'								,
		'ow_logo_quicktime'				: 'logo_qtlogo.gif'							,
		'ow_background_jog_slider'		: 'jogshuttle/barre_jogshuttle.png'		,
		'ow_image_jog_slider'			: 'jogshuttle/b_curseur_jogshuttle_petit.gif'	,
		'ow_image_sound_slider'			: 'volume_slider/b_curseur_volume_petit.gif',
		'ow_background_position_slider'	: 'timeline/fond_metre.gif'					,
		'ow_background_sound_slider'	: 'volume_slider/sound_bg_petit.gif'
	}
},

//  ===========================================================================
//  Preset pour METAL : defaut pour les client Opsomai opsomai OPSOMAI

movie_options_METAL: {
	width					: 320	,
	height					: 240	,
	controller_panel_width	: 344	,
	controller_panel_height	: 105 	, 
	window_position_x		: 50	,
	window_position_y		: 50	,
	window_default_width	: 400	,
	window_default_height	: 350	,
	free_lateral_width_in_FS: 360	,
	free_vertical_height	: 110	,
	movie_background_color	: '#CCCCCC',
	popUpFullscreen			: false	, 
	timecode_with_frame		: true	,	// if true, the frame are displayed
	autoplay				: true	,
	urlOfReplacementImage	: 'ow_images_OPSIS/boutons/b_play_petit.gif'	,
	urlOfEndImage			: 'ow_images_OPSIS/boutons/b_play_petit.gif'	,
	doNothingOnMovieFinished: true	,
	sound_handle_variable	: true	,
	debug_mode				: false	,
	sound_slider_height		: 11	,
	sound_slider_width		: 51	,
	position_slider_width	: 300	,
	imageRootURL			: 'ow_images_OPSIS/',	// location of the images 
	language				: 'fr'	,	// 'en' or 'fr' to get tooltips in French or English
	expectedQTversion		: '7.1'	,	
	quicktimeDetection		: false	,	
	code_controller 		: '<!-- Controller Design -->								 '	+
	'	<table border="0" cellpadding="0" cellspacing="0" id="tableSlider">				 '	+
	'		<!-- First Line +++++++++++++++++++++++++++++++++++++++++++++++     -->		 '	+
	'		<tr id="ligne-one">															 '	+
	'			<!-- Progress Bar +++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<td id="ow_id_progress_slider" class="controller" colspan="3">	</td>	 '	+
	'		</tr>																		 '	+
	'		<tr id="ligne-one-bis">														 '	+
	'			<td id="controller-help"><a id="ow_bouton_help"><img/></a></td>			 '	+
	'			<!-- TimeCode +++++++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<td id="controller-timecode"><p id="ow_id_timecode">--:--:--:--</p></td> '	+
	'			<td id="controller-logo"></td>		 '	+
	'		</tr>																		 '	+
	'		<tr id="ligne-two">															 '	+
	'			<!-- Sound  +++++++++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<td id="ow_id_sound_slider">	</td>									 '	+
	'			<!--  Retour Rapide +++++++++++++++++++++++++++++++++ 	-->				 '	+
	'			<td id="navigation"  colspan="2">										 '	+
	'				<a id="ow_bouton_go_to_beginning"><img/></a><a id="ow_bouton_fast_rewind"><img/></a><a id="ow_bouton_step_rewind"><img/></a><a id="ow_bouton_play_pause"><img/></a><a id="ow_bouton_step_forward"><img/></a><a id="ow_bouton_fast_forward"><img/></a><a id="ow_bouton_go_to_end"><img/></a><a id="ow_bouton_fullscreen"><img/></a>								 '	+
	'			</td>																	 '	+
	'		</tr>																		 '	+
	'	</table>',
		
	images					: {
		'ow_bouton_play'				: 'boutons/b_play_petit.png',
		'ow_bouton_pause'				: 'boutons/b_pause_petit.png',
		'ow_bouton_play_pause'			: 'boutons/b_play_petit.png',
		'ow_bouton_play_again'			: 'boutons/b_play_petit.png',
		'ow_bouton_fast_rewind'			: 'boutons/b_retour_rapide_petit.png',
		'ow_bouton_fast_forward'		: 'boutons/b_avance_rapide_petit.png',
		'ow_bouton_step_rewind'			: 'boutons/b_image_avant_petit.png',
		'ow_bouton_step_forward'		: 'boutons/b_image_apres_petit.png',
		'ow_bouton_go_to_end'			: 'boutons/b_aller_fin_petit.png',
		'ow_bouton_go_to_beginning'		: 'boutons/b_aller_debut_petit.png',
		'ow_bouton_fullscreen_open'		: 'boutons/b_plein_ecran_petit.png',
		'ow_bouton_fullscreen_close'	: 'boutons/b_plein_ecran_petit.png',
		'ow_bouton_mute_sound'			: 'boutons/b_hp_droit_petit.png',				
		'ow_bouton_max_sound'			: 'boutons/b_hp_droit_petit.png',
		'ow_bouton_logo_player'			: 'logo.png',	
		'ow_bouton_help'				: 'boutons/b_aide_petit.gif',
		'ow_logo_quicktime'				: 'logo_qtlogo.gif',
		'ow_image_position_slider'		: 'timeline/b_curseur_petit.png',
		'ow_image_selection_start_handle': 'timeline/LCDSliderSelectionStartMarker.gif',	
		'ow_image_selection_end_handle': 'timeline/LCDSliderSelectionEndMarker.gif',	
		// 'ow_image_sound_slider'			: 'volume_slider/b_curseur_volume_petit.png',	
		'ow_background_sound_slider'	: 'volume_slider/sound_bg_petit.gif',
		'ow_background_jog_slider'		: 'jogshuttle/barre_jogshuttle.png'		,
		'ow_image_jog_slider'			: 'jogshuttle/b_curseur_jogshuttle_petit.png'		,
		'ow_background_player'			: 'boutons/cache_fond_bt.png'		
	}

},



//  ===========================================================================
//  Preset pour l'INA : inamediapro

movie_options_INA: {
	width					: 320	,
	height					: 240	,
	controller_panel_width	: 320	,
	controller_panel_height	: 110 	, 
	free_vertical_height	: 125	,
	window_position_x		: 50	,
	window_position_y		: 50	,
	window_default_width	: 340	,
	window_default_height	: 334	,
	movie_background_color	: '#6c9bb2',
	popUpFullscreen			: false	, 
	timecode_with_frame		: true	,	// if true, the frame are displayed
	autoplay				: true	,
	urlOfFullscreenPage		: 'ow_template_fullscreen_INA.html'	,	// PHP: document.location.href.gsub(/[#]/, '') + '&FS=on',
	urlOfReplacementImage	: 'ow_images_INA/boutons/b_play_petit.gif'	,
	urlOfEndImage			: 'ow_images_INA/boutons/b_play_petit.gif'	,
	doNothingOnMovieFinished: true	,
	sound_handle_variable	: true	,
	selection_adjust_left	: 1		,
	advance_jog_shuttle		: false	,
	debug_mode				: false	,
	sound_slider_height		: 11	,
	sound_slider_width		: 51	,
	position_slider_width	: 300	,
	typeMime				: 'video/mpeg',
	imageRootURL			: 'ow_images_INA/',	// location of the images 
	language				: 'fr'	,	// 'en' or 'fr' to get tooltips in French or English
	expectedQTversion		: '7.3'	,
	quicktimeDetection		: false	,	
	should_select_all		: true	,
//	<td id="controller-logoINA"><a id="ow_bouton_logo_player"><img/></a></td>		
//	<td id="controller-help"><a id="ow_bouton_help"><img/></a></td>			
	code_controller 		: '<!-- Controller Design -->								 '	+
	'	<table border="0" cellpadding="0" cellspacing="0" id="tableSlider">				 '	+
	'		<!-- First Line +++++++++++++++++++++++++++++++++++++++++++++++     -->		 '	+
	'		<tr id="ligne-one">															 '	+
	'			<!-- Progress Bar +++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<td id="ow_id_progress_slider" class="controller" colspan="3">	</td>	 '	+
	'		</tr>																		 '	+
	'		<tr id="ligne-jog">															 '	+
	'			<!-- Jog Shuttle Bar +++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<td id="ow_id_jog_slider" class="controller" colspan="3">	</td>		 '	+
	'		</tr>																		 '	+
	'		<tr id="ligne-one-bis">														 '	+
	'			<td id="controller-help" colspan="3"> 	 '	+
	'				<a id="ow_bouton_left_sound"><img/></a> 							 '	+
	'				<a id="ow_bouton_right_sound"><img/></a> 							 '	+
	'				<a id="ow_bouton_help"><img/></a>									 '	+
	'			<!-- TimeCode +++++++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<span id="ow_id_timecode">--:--:--:--</span>						 '	+
	'			<span id="ow_id_jog_value"> </span>	 '	+
	'				</td>						 '	+
	'		</tr>																		 '	+
	'		<tr id="ligne-two">															 '	+
	'			<!-- Sound  +++++++++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<td id="ow_id_sound_slider" colspan="1">	</td>						 '	+
	'			<!--  Retour Rapide +++++++++++++++++++++++++++++++++ 	-->				 '	+
	'			<td id="navigation"  colspan="2">										 '	+
	'				<a id="ow_bouton_go_to_beginning"><img/></a><a id="ow_bouton_fast_rewind"><img/></a><a id="ow_bouton_step_rewind"><img/></a><a id="ow_bouton_play_pause"><img/></a><a id="ow_bouton_step_forward"><img/></a><a id="ow_bouton_fast_forward"><img/></a><a id="ow_bouton_go_to_end"><img/></a><a id="ow_bouton_fullscreen"><img/></a>								 '	+
	'			</td>																	 '	+
	'		</tr>																		 '	+
	'	</table>',
	images					: {
		'ow_bouton_play'				: 'boutons/b_play_petit.gif'			,
		'ow_bouton_pause'				: 'boutons/b_pause_petit.gif'			,
		'ow_bouton_play_pause'			: 'boutons/b_play_petit.gif'			,
		'ow_bouton_play_again'			: 'boutons/b_play_petit.gif'			,
		'ow_bouton_fast_rewind'			: 'boutons/b_retour_rapide_petit.gif'	,
		'ow_bouton_fast_forward'		: 'boutons/b_avance_rapide_petit.gif'	,
		'ow_bouton_step_rewind'			: 'boutons/b_image_avant_petit.gif'		,
		'ow_bouton_step_forward'		: 'boutons/b_image_apres_petit.gif'		,
		'ow_bouton_go_to_end'			: 'boutons/b_aller_fin_petit.gif'		,
		'ow_bouton_go_to_beginning'		: 'boutons/b_aller_debut_petit.gif'		,
		'ow_bouton_fullscreen_open'		: 'boutons/b_plein_ecran_petit.gif'		,
		'ow_bouton_fullscreen_close'	: 'boutons/b_plein_ecran_petit.gif'		,
		'ow_bouton_mute_sound'			: 'boutons/b_hp_droit_petit.gif'		,
		'ow_bouton_max_sound'			: 'boutons/b_hp_droit_petit.gif'		,
		'ow_bouton_left_sound'			: 'boutons/b_hp_gauche_petit_onde.gif'	,
		'ow_bouton_right_sound'			: 'boutons/b_hp_droit_petit_onde.gif'	,
		'ow_bouton_left_sound_off'		: 'boutons/b_hp_gauche_petit_stop.gif'	,
		'ow_bouton_right_sound_off'		: 'boutons/b_hp_droit_petit_stop.gif'	,
		'ow_bouton_logo_player'			: 'logo.gif'							,	
		'ow_bouton_help'				: 'boutons/b_aide_petit.gif'			,
		'ow_logo_quicktime'				: 'logo_qtlogo.gif'						,
		'ow_image_position_slider'		: 'timeline/curseur.gif'				,
		// 'ow_image_sound_slider'			: 'volume_slider/b_curseur_volume_petit.gif',	
		'ow_background_sound_slider'	: 'volume_slider/sound_bg_petit.gif'	,	
		'ow_background_jog_slider'		: 'jogshuttle/barre_jogshuttle.png'		,
		'ow_image_jog_slider'			: 'jogshuttle/b_curseur_jogshuttle_petit.png'		,
		'ow_bouton_beg_selection'		: 'boutons/b_definir_debut_petit.gif'	,	
		'ow_bouton_end_selection'		: 'boutons/b_definir_fin_petit.gif'		,	
		'ow_bouton_save_selection'		: 'boutons/b_disquette_petit.png'		,	
		'ow_bouton_new_selection'		: 'boutons/b_nouv_chap_petit.gif'		,	
		'ow_bouton_annotate_selection'	: 'boutons/b_annoter_petit.gif'
	},
	images_pressed					: {
		'ow_bouton_play'				: 'boutons/b_play_petit.gif'			,
		'ow_bouton_pause'				: 'boutons/b_pause_petit.gif'			,
		'ow_bouton_play_pause'			: 'boutons/b_play_petit.gif'			,
		'ow_bouton_play_again'			: 'boutons/b_play_petit.gif'			,
		'ow_bouton_fast_rewind'			: 'boutons_pressed/b_retour_rapide_petit.gif'	,
		'ow_bouton_fast_forward'		: 'boutons_pressed/b_avance_rapide_petit.gif'	,
		'ow_bouton_step_rewind'			: 'boutons_pressed/b_image_avant_petit.gif'		,
		'ow_bouton_step_forward'		: 'boutons_pressed/b_image_apres_petit.gif'		,
		'ow_bouton_go_to_end'			: 'boutons/b_aller_fin_petit.gif'		,
		'ow_bouton_go_to_beginning'		: 'boutons/b_aller_debut_petit.gif'		,
		'ow_bouton_fullscreen_open'		: 'boutons/b_plein_ecran_petit.gif'		,
		'ow_bouton_fullscreen_close'	: 'boutons/b_plein_ecran_petit.gif'		,
		'ow_bouton_mute_sound'			: 'boutons/b_hp_droit_petit.gif'		,
		'ow_bouton_max_sound'			: 'boutons/b_hp_droit_petit.gif'		,
		'ow_bouton_left_sound'			: 'boutons/b_hp_gauche_petit_onde.gif'	,
		'ow_bouton_right_sound'			: 'boutons/b_hp_droit_petit_onde.gif'	,
		'ow_bouton_left_sound_off'		: 'boutons/b_hp_gauche_petit_stop.gif'	,
		'ow_bouton_right_sound_off'		: 'boutons/b_hp_droit_petit_stop.gif'	,
		'ow_bouton_logo_player'			: 'logo.gif'							,	
		'ow_bouton_help'				: 'boutons/b_aide_petit.gif'			,
		'ow_logo_quicktime'				: 'logo_qtlogo.gif'						,
		'ow_image_position_slider'		: 'timeline/curseur.gif'				,
		// 'ow_image_sound_slider'			: 'volume_slider/b_curseur_volume_petit.gif',	
		'ow_background_sound_slider'	: 'volume_slider/sound_bg_petit.gif'	,	
		'ow_background_jog_slider'		: 'jogshuttle/barre_jogshuttle.png'		,
		'ow_image_jog_slider'			: 'jogshuttle/b_curseur_jogshuttle_petit.png'		,
		'ow_bouton_beg_selection'		: 'boutons/b_definir_debut_petit.gif'	,	
		'ow_bouton_end_selection'		: 'boutons/b_definir_fin_petit.gif'		,	
		'ow_bouton_save_selection'		: 'boutons/b_disquette_petit.png'		,	
		'ow_bouton_new_selection'		: 'boutons/b_nouv_chap_petit.gif'		,	
		'ow_bouton_annotate_selection'	: 'boutons/b_annoter_petit.gif'
	}
},

//  ===========================================================================
//  Preset pour l'INA radio : inamediapro RADIO : son SON

movie_options_INA_radio: {
	sound_level				: true,
	width					: 320	,
	height					: 240	,
	controller_panel_width	: 320	,
	controller_panel_height	: 110 	, 
	free_lateral_width_in_FS: 235	,
	free_vertical_height	: 125	,
	free_height_above		: 25	,
	sound_balance			: 0		,
	window_position_x		: 50	,
	window_position_y		: 50	,
	window_default_width	: 340	,
	window_default_height	: 334	,
	movie_background_color	: '#6c9bb2',
	popUpFullscreen			: false	, 
	timecode_with_frame		: true	,	// if true, the frame are displayed
	autoplay				: true	,
	urlOfFullscreenPage		: 'ow_template_fullscreen_INA.html'	,	// PHP: document.location.href.gsub(/[#]/, '') + '&FS=on',
	urlOfReplacementImage	: 'ow_images_INA/boutons/b_play_petit.gif'	,
	urlOfEndImage			: 'ow_images_INA/boutons/b_play_petit.gif'	,
	doNothingOnMovieFinished: true	,
	sound_handle_variable	: true	,
	selection_adjust_left	: 1		,
	advance_jog_shuttle		: false	,
	debug_mode				: false	,
	sound_slider_height		: 11	,
	sound_slider_width		: 51	,
	position_slider_width	: 300	,
	typeMime				: 'video/mpeg',
	imageRootURL			: 'ow_images_INA/',	// location of the images 
	language				: 'fr'	,	// 'en' or 'fr' to get tooltips in French or English
	expectedQTversion		: '7.3'	,
	quicktimeDetection		: false	,	
	should_select_all		: true	,
//	<td id="controller-logoINA"><a id="ow_bouton_logo_player"><img/></a></td>		
//	<td id="controller-help"><a id="ow_bouton_help"><img/></a></td>			
	code_controller 		: '<!-- Controller Design -->								 '	+
	'	<table border="0" cellpadding="0" cellspacing="0" id="tableSlider">				 '	+
	'		<!-- First Line +++++++++++++++++++++++++++++++++++++++++++++++     -->		 '	+
	'		<tr id="ligne-one">															 '	+
	'			<!-- Progress Bar +++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<td id="ow_id_progress_slider" class="controller" colspan="3">	</td>	 '	+
	'		</tr>																		 '	+
	'		<tr id="ligne-jog">															 '	+
	'			<!-- Jog Shuttle Bar +++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<td id="ow_id_jog_slider" class="controller" colspan="3">	</td>		 '	+
	'		</tr>																		 '	+
	'		<tr id="ligne-one-bis">														 '	+
	'			<td id="controller-help" colspan="3"> 	 '	+
	'				<a id="ow_bouton_help"><img/></a>									 '	+
	'			<!-- TimeCode +++++++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<span id="ow_id_timecode">--:--:--:--</span>						 '	+
	'			<span id="ow_id_jog_value"> </span>	 '	+
	'				</td>						 '	+
	'		</tr>																		 '	+
	'		<tr id="ligne-two">															 '	+
	'			<!-- Sound  +++++++++++++++++++++++++++++++++++++++++++++++ 	-->		 '	+
	'			<td id="ow_id_sound_slider" colspan="1">	</td>						 '	+
	'			<!--  Retour Rapide +++++++++++++++++++++++++++++++++ 	-->				 '	+
	'			<td id="navigation"  colspan="2">										 '	+
	'				<a id="ow_bouton_go_to_beginning"><img/></a><a id="ow_bouton_fast_rewind"><img/></a><a id="ow_bouton_step_rewind"><img/></a><a id="ow_bouton_play_pause"><img/></a><a id="ow_bouton_step_forward"><img/></a><a id="ow_bouton_fast_forward"><img/></a><a id="ow_bouton_go_to_end"><img/></a><a id="ow_bouton_fullscreen"><img/></a>								 '	+
	'			</td>																	 '	+
	'		</tr>																		 '	+
	'	</table>',
	images					: {
		'ow_bouton_play'				: 'boutons/b_play_petit.gif'			,
		'ow_bouton_pause'				: 'boutons/b_pause_petit.gif'			,
		'ow_bouton_play_pause'			: 'boutons/b_play_petit.gif'			,
		'ow_bouton_play_again'			: 'boutons/b_play_petit.gif'			,
		'ow_bouton_fast_rewind'			: 'boutons/b_retour_rapide_petit.gif'	,
		'ow_bouton_fast_forward'		: 'boutons/b_avance_rapide_petit.gif'	,
		'ow_bouton_step_rewind'			: 'boutons/b_image_avant_petit.gif'		,
		'ow_bouton_step_forward'		: 'boutons/b_image_apres_petit.gif'		,
		'ow_bouton_go_to_end'			: 'boutons/b_aller_fin_petit.gif'		,
		'ow_bouton_go_to_beginning'		: 'boutons/b_aller_debut_petit.gif'		,
		'ow_bouton_fullscreen_open'		: 'boutons/b_plein_ecran_petit.gif'		,
		'ow_bouton_fullscreen_close'	: 'boutons/b_plein_ecran_petit.gif'		,
		'ow_bouton_mute_sound'			: 'boutons/b_hp_droit_petit.gif'		,
		'ow_bouton_max_sound'			: 'boutons/b_hp_droit_petit.gif'		,
		'ow_bouton_left_sound'			: 'boutons/b_hp_gauche_petit_onde.gif'	,
		'ow_bouton_right_sound'			: 'boutons/b_hp_droit_petit_onde.gif'	,
		'ow_bouton_left_sound_off'		: 'boutons/b_hp_gauche_petit_stop.gif'	,
		'ow_bouton_right_sound_off'		: 'boutons/b_hp_droit_petit_stop.gif'	,
		'ow_bouton_logo_player'			: 'logo.gif'							,	
		'ow_bouton_help'				: 'boutons/b_aide_petit.gif'			,
		'ow_logo_quicktime'				: 'logo_qtlogo.gif'						,
		'ow_image_position_slider'		: 'timeline/curseur.gif'				,
		// 'ow_image_sound_slider'			: 'volume_slider/b_curseur_volume_petit.gif',	
		'ow_background_sound_slider'	: 'volume_slider/sound_bg_petit.gif'	,	
		'ow_background_jog_slider'		: 'jogshuttle/barre_jogshuttle.png'		,
		'ow_image_jog_slider'			: 'jogshuttle/b_curseur_jogshuttle_petit.png'		,
		'ow_bouton_beg_selection'		: 'boutons/b_definir_debut_petit.gif'	,	
		'ow_bouton_end_selection'		: 'boutons/b_definir_fin_petit.gif'		,	
		'ow_bouton_save_selection'		: 'boutons/b_disquette_petit.png'		,	
		'ow_bouton_new_selection'		: 'boutons/b_nouv_chap_petit.gif'		,	
		'ow_bouton_annotate_selection'	: 'boutons/b_annoter_petit.gif'
	}	,
	images_pressed					: {
		'ow_bouton_play'				: 'boutons/b_play_petit.gif'			,
		'ow_bouton_pause'				: 'boutons/b_pause_petit.gif'			,
		'ow_bouton_play_pause'			: 'boutons/b_play_petit.gif'			,
		'ow_bouton_play_again'			: 'boutons/b_play_petit.gif'			,
		'ow_bouton_fast_rewind'			: 'boutons_pressed/b_retour_rapide_petit.gif'	,
		'ow_bouton_fast_forward'		: 'boutons_pressed/b_avance_rapide_petit.gif'	,
		'ow_bouton_step_rewind'			: 'boutons_pressed/b_image_avant_petit.gif'		,
		'ow_bouton_step_forward'		: 'boutons_pressed/b_image_apres_petit.gif'		,
		'ow_bouton_go_to_end'			: 'boutons/b_aller_fin_petit.gif'		,
		'ow_bouton_go_to_beginning'		: 'boutons/b_aller_debut_petit.gif'		,
		'ow_bouton_fullscreen_open'		: 'boutons/b_plein_ecran_petit.gif'		,
		'ow_bouton_fullscreen_close'	: 'boutons/b_plein_ecran_petit.gif'		,
		'ow_bouton_mute_sound'			: 'boutons/b_hp_droit_petit.gif'		,
		'ow_bouton_max_sound'			: 'boutons/b_hp_droit_petit.gif'		,
		'ow_bouton_left_sound'			: 'boutons/b_hp_gauche_petit_onde.gif'	,
		'ow_bouton_right_sound'			: 'boutons/b_hp_droit_petit_onde.gif'	,
		'ow_bouton_left_sound_off'		: 'boutons/b_hp_gauche_petit_stop.gif'	,
		'ow_bouton_right_sound_off'		: 'boutons/b_hp_droit_petit_stop.gif'	,
		'ow_bouton_logo_player'			: 'logo.gif'							,	
		'ow_bouton_help'				: 'boutons/b_aide_petit.gif'			,
		'ow_logo_quicktime'				: 'logo_qtlogo.gif'						,
		'ow_image_position_slider'		: 'timeline/curseur.gif'				,
		// 'ow_image_sound_slider'			: 'volume_slider/b_curseur_volume_petit.gif',	
		'ow_background_sound_slider'	: 'volume_slider/sound_bg_petit.gif'	,	
		'ow_background_jog_slider'		: 'jogshuttle/barre_jogshuttle.png'		,
		'ow_image_jog_slider'			: 'jogshuttle/b_curseur_jogshuttle_petit.png'		,
		'ow_bouton_beg_selection'		: 'boutons/b_definir_debut_petit.gif'	,	
		'ow_bouton_end_selection'		: 'boutons/b_definir_fin_petit.gif'		,	
		'ow_bouton_save_selection'		: 'boutons/b_disquette_petit.png'		,	
		'ow_bouton_new_selection'		: 'boutons/b_nouv_chap_petit.gif'		,	
		'ow_bouton_annotate_selection'	: 'boutons/b_annoter_petit.gif'
	}
},


/****************************************************************************************/
/*	HELP 																				*/
/*		HELP to the Installation and the configuration / Aide config help aide			*/
/*	open the player as usually, with the parameter help set to true to display the help	*/
/*																				HELP	*/
/****************************************************************************************/

AttachConfigHelpPanel: function() {
	this.container = $(this.containerName);
	var code, property, tversion;
	code = '<div id="ow_configuration_panel"><h1 id="TOP">How to Configure OroaWeb</h1>\n';

	code += '<h3 id="version_orao_top">The version of OraoWeb you are looking at is : <span  id="version_number_orao_top">'+ OW_OraoWeb_version + '</span> released on the <span  id="version_date_orao_top">'+ OW_OraoWeb_version_release_date + '</span><br/>The used preset is :<span  id="version_preset_orao_top"> '+this.movie_options.preset+'</span> and the image directory is :<span  id="version_image_orao_top"> '+this.movie_options.imageRootURL+'</span><br/><a href="#version_orao" class="to_version_orao">More informations about the versions</a></h3>';

	
	code += '\n<h3>Go straight  to the <b><a href="#Properties">Parameters</a></b>, the <b><a href="#ReleasesNotes">Releases Notes</a></b>, the <b><a href="#ToDo">ToDo List</a></b> or the <b><a href="#Bug">Bug List</a></b> or <b><a href="#ConfigAPI">the Public API</a></b></h3><hr/>';
	
	code += '<p>Start with a look at the two main template : <a href="ow_template.html">ow_template</a> for the main page or the iFrame and <a href="ow_template_fullscreen.html">ow_template_fullscreen</a> which is the page that will be used when opening a full screen window (there is no need for this second template when the option \'popUpFullscreen\' is set to false, which is now the case for most of our projects).</p>';
	code += '<p>Then have a look at the template <b>using a preset</b> : <ul><li>CNRS "<code> preset :\'movie_options_CNRS\', </code>" : <a href="ow_template_CNRS.html">ow_template_CNRS</a> for the main page or the iFrame and <a href="ow_template_fullscreen_CNRS.html">ow_template_fullscreen_CNRS</a> ( +  <a href="ow_css_CNRS.css">ow_css_CNRS.css</a>)</li><li>INA  "<code> preset :\'movie_options_INA\', </code>" : a window that will be resized by the the player and with a lateral div to place the extract list : <a href="ow_template_INA.html">ow_template_INA.html</a> ( +  <a href="ow_css_INA.css">ow_css_INA.css</a>)</li><li>INA_radio"<code> preset :\'movie_options_INA_radio\', </code>" : a window that will be resized by the the player and with a lateral div to place the extract list : <a href="ow_template_INA_radio.html">ow_template_INA_radio.html</a> ( +  <a href="ow_css_INA.css">ow_css_INA.css</a>). Note that this preset contains the parameter <code>sound_level</code> set to true in order to display a flash animation of the sound level</li><li>LNR  "<code> preset :\'movie_options_LNR\', </code>" : <a href="ow_template_LNR.html">ow_template_LNR</a> for the main page or the iFrame and <a href="ow_template_fullscreen_LNR.html">ow_template_fullscreen_LNR</a> ( +  <a href="ow_css_LNR.css">ow_css_LNR.css</a>)</li><li>OPSIS  "<code> preset :\'movie_options_OPSIS\', </code>" , the latest one, default for OPSIS project, e.g. the "Ateliers des Images" : a window that will be resized by the the player and with a lateral div to place the extract list : <a href="ow_template_OPSIS.html">ow_template_OPSIS</a> ( +  <a href="ow_css_OPSIS.css">ow_css_OPSIS.css</a>)</li></ul>To use such preset, there are just two slight modifications to the default usage :<ul><li>a <a href="ow_css_CNRS.css">complementary CSS file (\'ow_css_CNRS\')</a> is added to the header AFTER the default one (Note that you should do the same when you want to alter the default preset)</li><li>a property (<a href="#Preset">see info on \'preset\'</a>) is added to specify a preset (if you want to add one, otherwise, the default one is used)</li></ul></p>';
	
	// INSTALLATION : THE FILES
	code += '<h4 id="INSTALL">To install OroaWeb, you need... <span class="local_menu"><a href="#TOP" class="back_to_top">Back To Top</a> - <a href="#version_orao" class="next_to">Next</a></span></h4> <ol><li><a href="'+ this.movie_options.imageRootURL +'">A directory full of images</a> (<b>Opsis:</b> \'/design/images/ow_images/\' or <b>INA:</b> \'/ow_images_INA\'/)</li><li>Two CSS files : <a href="ow_css.css">the default ow_css.css</a>  and the preset specific one (<b>Opsis:</b> \'<a href="ow_css_OPSIS.css">/design/ow_css_OPSIS.css</a>\' or <b>INA:</b> \'<a href="ow_css_INA.css">/ow_css_INA.css</a>\')</li><li><a href="ow_javascript/">A set of 4 or 5 javascript files</a> (from the following subdirectory : \'/ow_javascript/\') : <code>AC_QuickTime.js</code> (Apple, to write the QT plug-in call), <code>OPS_prototype1602.js</code> (modified version of prototype 1.6.0.2), <code>slider.js</code> (Spriptaculous) and <code><b>OW_Player.js</b></code> : the main work from Opsomai. In addition, if you want to display the sound envelope, you will need the 5th file <code>AC_RunActiveContent.js</code> (Adobe, to include a Flash object)</li><li>One or two template files (<a href="ow_template.html">ow_template</a> and <a href="ow_template_fullscreen.html">ow_template_fullscreen</a>) as examples of inclusion of the player into an HTML page (<b>Opsis:</b> visualisationQT.inc.php and video.html)</li></ol>';

		// TEMPLATES
	code += '<p>From the templates, provided as some simple usage examples, you will notice that <b>all the configuration</b> (except for the name of the container) <b>is done by filling an hash <a href="#Properties">table of properties</a></b>. For instance as soon as this hash table set the \'config_help\' property to  \'true\', this present help panel is displayed instead of the actual OraoWeb Quicktime viewer</p><p> The main aspect of the inclusion are the following :<p>	';
	code += '1) Make sure to use the proper headers and utf8 encoding<br/><code>&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Transitional//EN&quot; &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd&quot;&gt;<br>&lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot; xml:lang=&quot;fr&quot; lang=&quot;fr&quot;&gt;<br>\t&lt;head&gt;<br>\t\t&lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=utf-8&quot;/&gt;	</code></p>';
	code += '<p>2) Includes javascript and CSS files<br><code>\t&lt;script type=&quot;text/javascript&quot; src=&quot;ow_javascript/OPS_prototype1602.js&quot;&gt;&lt;/script&gt;<br>\t&lt;script type=&quot;text/javascript&quot; src=&quot;ow_javascript/ac_quicktime12.js&quot;&gt;&lt;/script&gt;<br>\t&lt;script type=&quot;text/javascript&quot; src=&quot;ow_javascript/slider.js&quot;&gt;&lt;/script&gt;<br>\t&lt;script type=&quot;text/javascript&quot; src=&quot;ow_javascript/OW_Player.js&quot;&gt;&lt;/script&gt;<br>\t&lt;link rel=&quot;stylesheet&quot; href=&quot;ow_css.css&quot; type=&quot;text/css&quot; media=&quot;screen&quot; title=&quot;OraoWeb&quot; charset=&quot;utf-8&quot; /&gt;<br>\t&lt;link rel=&quot;stylesheet&quot; href=&quot;ow_css_INA.css&quot; type=&quot;text/css&quot; media=&quot;screen&quot; title=&quot;OraoWeb&quot; charset=&quot;utf-8&quot; /&gt;</code> </br></p>';
	code += '<p>3) Use the magic recipe to properly size the window (the same will be used when going back from the FS)<br><code> &lt;script type=&quot;text/javascript&quot; charset=&quot;utf-8&quot;&gt;<br>var	_window_position_x		= 50	;<br>var _window_position_y		= 50	;<br>var _window_default_width	= 570<br>var _window_default_height	= 400	;<br>// 40 et 220 sont des tempons : des estimations grossieres que ce que coute les bords d\'une fenetre<br>window.resizeTo(_window_default_width + 40, _window_default_height + 220);<br>var _offset_width 	= _window_default_width + 40 - document.viewport.getWidth();<br>var _offset_height	= _window_default_height + 220 - document.viewport.getHeight();<br>window.resizeTo(_window_default_width + _offset_width, _window_default_height + _offset_height);<br>window.moveTo(_window_position_x,_window_position_y);	<br>window.focus();	<br>&lt;/script&gt; </code></p>';
	code += '<p>4) Add an empty DIV "container" somewhere in the page.</p>';
	code += '<p>5) Outside of the DIV "container" and, mainly for the pleasure of that poor IE, as close as possible to the closing /body, insert the javascript code : declare a variable <code>OW_Player</code> (*), declare an hashtable of parameters, and then instantiate the object (with the id of the div container and the hashtable of parameters) and put its reference into the OW_Player variable.<br>(*) If you want to change the name of this variable, you have to tell it to the flash object by modifying the value of the following variable : <code>defaultNameOfOraoWebObject = \'OW_Player\'</code><br><code>&lt;script type=&quot;text/javascript&quot;&gt;<br>&lt;!-- <br>var OW_Player;<br>var player_options = {<br>url							: &#x27;http://videotheque.cnrs.fr/media/videos/M01445.mp4&#x27;,<br>preset					: &#x27;movie_options_INA&#x27;	,<br>// typeMime				: &#x27;video/quicktime&#x27;		,		// Dans le cas d&#x27;un QTRef de logotisation !<br>// typeMime				: &#x27;audio/mpeg&#x27;			,		// Pour un MPEG1 en direct<br>typeMime				: &#x27;video/mp4&#x27;			,		// Dans le cas d&#x27;un mpeg 4<br>imageRootURL			: &#x27;ow_images_INA/&#x27;		,<br> ../..<br>help_panel_target		: &#x27;sidecommande&#x27;		,<br>window_position_x		: _window_position_x	,<br>window_position_y		: _window_position_y	,<br>window_default_width	: _window_default_width	,<br>window_default_height	: _window_default_height,<br>onMovieFullScreen		: function() {<br>$(&#x27;sidecommande&#x27;).setStyle({height: (document.viewport.getHeight() - 65 )+&#x27;px&#x27;});<br>},<br> ../.. <br>language				: &#x27;fr&#x27;<br>};<br>OW_Player = new OW_OraoWeb_Player(&#x27;container&#x27;, player_options);<br>--&gt;<br>&lt;/script&gt;<br>&lt;/div&gt;</code>  </p>';
	
	
	// PRESENT CONTEXT
	code += '<h3 id="version_orao">The version of OraoWeb you are looking at is : <span  id="version_number_orao">'+ OW_OraoWeb_version + '</span> released on the <span  id="version_date_orao">'+ OW_OraoWeb_version_release_date + '</span><br>The used preset is :<span  id="version_preset_orao"> '+this.movie_options.preset+'</span> and the image directory is :<span  id="version_image_orao"> '+this.movie_options.imageRootURL+'</span></h3><span class="local_menu"><a href="#TOP" class="back_to_top">Back To Top</a> - <a href="#Properties" class="next_to">Next</a> - <a href="#INSTALL" class="previous_to">Previous</a></span>';
	code += '<p>You can always get the <b>latest stable version</b> at : <a href="'+OW_OraoWeb_host+'/stable3/ow_help.html">'+OW_OraoWeb_host+'/stable3/ow_help.html</a><br> Another stable release is also available on the official opsomai demo web site : <a href="http://demo.opsismedia.com">http://demo.opsismedia.com</a> (but this one will probably not be the latest one)</p>';
	code += '<p>You can always get <b>the latest work in progress (beta)</b> at : <a href="'+OW_OraoWeb_host+'/dev3/ow_help.html">'+OW_OraoWeb_host+'/dev3/ow_help.html</a></p>';
	
	// 3 VERSIONS
	code += '<h3>There had been 3 major versions of OraoWeb : </h3>(See the <a href="#ReleasesNotes">Releases Notes</a> to get a detail of the minor version)<ul><li><a href="'+OW_OraoWeb_host+'/stable/ow_template_INA.html">Version 1</a> : 2 or 3 javascript loops regularly query loading status and position within the media. Not the most optimised option, but would work with Safari 2</li><li><a href="'+OW_OraoWeb_host+'/stable2/ow_template_INA.html">Version 2</a> : listen to QuickTime plug-in Events for a better optimisation. Start working with Safari2, IE6, FF2</li><li><a href="'+OW_OraoWeb_host+'/stable3/ow_template_INA.html">Version 3</a> : provide in a same tool a video and a sound player : the sound version include a Flash object synchronised to the QuickTime one trough javascript, in order to display to different scale of the sound envelop</li></ul>';
	
	
	// Lots of PARAMETERS
	code += '\n <hr/>\n';			
	code += '\n <h2 id="Properties">Properties/parameters, or how to configure the player <span class="local_menu"><a href="#TOP" class="back_to_top">Back To Top</a> - <a href="#Containers" class="next_to">Next</a> - <a href="#version_orao" class="previous_to">Previous</a></span></h2>\n';			
	code += '<p>Here after, the list of the properties, their present values (the default ones if you haven\'t overwritten them), and a short explanation of their usage. By present value, we mean that if you set to true the property \'config_help\' from within your own implementation, you will see hereafter the actual value that you are using (taking into account default, preset and manually set value in the precedence order)</p>';
	code += '\n<table id="table_properties">';
	property;
	for (property in this.config_description) {
		if (property.match(/^cc(\d+)/))	{
			// <td class="ow_config_property_part_key">Group '+ property.substr(2)+'</td>
			code += '<tr id="ow_config_property_'+property+ '" class="ow_config_property_part"> <td class="ow_config_property_part_description" colspan="2">'+this.config_description[property]+'</td></tr>\n';
		}	else	{
			code += '<tr id="ow_config_property_'+property+ '" class="ow_config_property"><td class="ow_config_property_key">'+property+'</td> <td class="ow_config_property_description">'+this.config_description[property]+'</td></tr>\n';
			if ( this.movie_options[property] && this.movie_options[property].escapeHTML )	{
				code += '<tr class="ow_config_value"><td class="ow_config_value_title">Default value : </td> <td class="ow_config_value_default">'+this.movie_options[property].escapeHTML() +'</td></tr>\n';
			}
			else	{
				code += '<tr class="ow_config_value"><td class="ow_config_value_title">Default value : </td> <td class="ow_config_value_default"> '+this.movie_options[property] +' </td></tr>\n';
			}
		}
	}				
	code += '</table>\n';
	
	code += '\n <h3 id="Containers">Containers for main interaction tools <span class="local_menu"><a href="#TOP" class="back_to_top">Back To Top</a> - <a href="#Buttons" class="next_to">Next</a> - <a href="#Properties" class="previous_to">Previous</a></span></h3>\n';
	code += '\n <p>Each div or element which id match one of the following one will be automatically added the matching callback ';
	code += '\n function trough an onclick. Then, if it contains an \'img\' element, this contained img will be attributed the correct image ';
	code += '\n and the matching tooltips. ';
	code += '\n <br>Eg : <br><code>';
	code += '\n <a id="ow_bouton_play"><img></a>'.escapeHTML();
	code += '\n </code><br>would be replaced by the javascript equivalent of <br><code>';
	code += '\n <a id="ow_bouton_play" href="#" onclick="..."><img src="../images/videoPlayer/Play.gif" alt="Lance la vidéo" title="Lance la vidéo"/></a> '.escapeHTML();
	code += '\n </code><br>The container (td, p, div, span...) with the matching id will host the matching complex object ';
	code += '\n <table id="table_container">\n';
	for (property in this.config_container) {
		if (this.config_container.hasOwnProperty(property))	{
			code += '<tr class="ow_config_property"><td class="ow_config_property_key">'+property+'</td> <td class="ow_config_property_description">'+this.config_container[property]+'</td></tr>\n';
		}
	}				
	code += '\n</table>\n';				
	
	
	code += '\n <h3 id="Buttons">Buttons and images <span class="local_menu"><a href="#TOP" class="back_to_top">Back To Top</a> - <a href="#Tooltips" class="next_to">Next</a> - <a href="#Containers" class="previous_to">Previous</a></span></h3>\n';			
	code += '<table  id="table_buttons">';
	for (property in this.config_images) {
		if (this.config_images.hasOwnProperty(property))	{
			code += '<tr class="ow_config_property"><td class="ow_config_property_key">'+property+'</td> <td class="ow_config_property_description">'+this.config_images[property]+'</td></tr>\n';
			code += '<tr id="ow_config_value"><td id="ow_config_extract" colspan="1"><code> \''+ property +'\'\t\t: \''+this.movie_options.images[property] +'\' , </code></td> <td><img src="'+ this.movie_options.imageRootURL + this.movie_options.images[property] +'"></td> </tr>\n';
		}
	}				
	code += '</table>\n';
	
	code += '\n <h3 id="Tooltips">Tooltips and other translated messages <span class="local_menu"><a href="#TOP" class="back_to_top">Back To Top</a> - <a href="#ConfigAPI" class="next_to">Next</a> - <a href="#Buttons" class="previous_to">Previous</a></span></h3>\n';			
	code += '<table  id="table_tooltips">';
	for (property in this.config_tooltips) {
		if (this.config_tooltips.hasOwnProperty(property))	{
			code += '<tr class="ow_config_property"><td class="ow_config_property_key">'+property+'</td> <td class="ow_config_property_description">'+this.config_tooltips[property]+'</td></tr>\n';
			code += '<tr id="ow_config_value"><td id="ow_config_extract" colspan="2"><code>FR: \''+ property +'\'\t\t: \''+this.movie_options.tooltips_fr[property].escapeHTML() +'\' , <br>EN: \''+ property +'\'\t\t: \''+this.movie_options.tooltips_en[property].escapeHTML() +'\'</code></td></tr>\n';
		}
	}				
	code += '</table>\n';


	code += '\n <h3 id="ConfigAPI">API : How to interact with the player <span class="local_menu"><a href="#TOP" class="back_to_top">Back To Top</a> - <a href="#ReleasesNotes" class="next_to">Next</a> - <a href="#Tooltips" class="previous_to">Previous</a></span></h3>\n';			
	code += '<p>Theoritically, one may directly access any function define in the OW_OraoWeb_Player object. If one use <code>var OW_Player = new OW_OraoWeb_Player(\'container\', player_options);</code> to define a player, then one may call a function LetDoSomething by : <code>OW_Player.LetDoSomething()</code>.<br>For stability reason, only the following listed functions are expected to be public (and should not change)';
	code += '\n<table  id="table_api">';
	for (property in this.config_API) {
		if (this.config_API.hasOwnProperty(property))	{
			code += '<tr class="ow_config_function"><td class="ow_config_function_call">'+property+'</td> <td class="ow_config_function_description">'+this.config_API[property]+'</td></tr>\n';
		}
	}				
	code += '</table>\n';
	
	
	code += '\n <h3 id="ReleasesNotes">Releases Notes <span class="local_menu"><a href="#TOP" class="back_to_top">Back To Top</a> - <a href="#ToDo" class="next_to">Next</a> - <a href="#ConfigAPI" class="previous_to">Previous</a></span></h3>\n';			
	code += 'Clic on the version number to get to its archive';
	code += '<table  id="table_releases">';
	$A(this.releases_notes).each(function(version) {
			tversion = version.version;
			tversion = tversion.gsub(/[.]/,'');
			code += '<tr class="ow_config_property" id="ReleasesNotes'+ tversion +'"><td class="ow_config_property_key"><a href="'+ version.url + '">' +version.version+'</a></td> <td class="ow_config_property_key">'+version.release+'</td> <td class="ow_config_property_description">'+version.description;
		if (version.todos_and_bugs)	{
			$A(version.todos_and_bugs).each(function(modif) {
				if(!modif.priority) 	{	return;	}
				if (modif.bug)	{
					code += '<br> + Bug : \n'+modif.description;
				}	else	{
					code += '<br> + Plus : \n'+modif.description;
				}
			});
		}
		code += '</td></tr>\n';
	});
	code += '</table>\n';
	
	code += '\n <h3 id="ToDo">ToDo List <span class="local_menu"><a href="#TOP" class="back_to_top">Back To Top</a> - <a href="#Bug" class="next_to">Next</a> - <a href="#ReleasesNotes" class="previous_to">Previous</a></span></h3>\n';			
	code += '<table id="ow_config_todos">';
	$A(this.todos).each(function(todo) {
		if(!todo.priority) 	{	return;	}
			code += '<tr class="ow_config_todo"><td class="ow_config_todo_priority">'+todo.priority+'</td> <td class="ow_config_todo_description">'+todo.description+'</td></tr>\n';
	});
	code += '</table>\n';
	
	code += '\n <h3 id="Bug">Bug List <span class="local_menu"><a href="#TOP" class="back_to_top">Back To Top</a> - <a href="#ToDo" class="previous_to">Previous</a></span></h3>\n';			
	code += '<table id="ow_config_bugs">';
	$A(this.bugs).each(function(bug) {
		if(!bug.priority) 	{	return;	}
			code += '<tr class="ow_config_bug"><td class="ow_config_bug_priority">'+bug.priority+'</td> <td class="ow_config_bug_description">'+bug.description+'</td></tr>\n';
	});
	code += '</table>\n';
	
	
	code += '\n</div>\n';
	this.container.update(code);
},

// Description of the parameters
config_description: {
	cc1						: 'Main parameters'	,
	url						: 'URL of the video of the movie to display. Must start with http:// or be an URL relative to the calling page'	,
	preset					: '<a id="Preset">the name of a set of configuration.</a> There should be about 3 or 4 of them. Right now there are only two (in addition to the default one): \'movie_options_CNRS\' and \'movie_options_LNR\' (this latest is the same as the default one for the moment). The default config is loaded first, then the one from the preset overwrite the parameter set in the optional chosen preset and eventually the options define in the call to create the viewer overwrite everything else, getting indeed the highest priority. If one want to know what is in a given preset, one way is to look at it, the other is to just call the viewer with two option set : \'help\' (true) and \'preset\' with the name of the preset as a parameter', 
	sound_level				: 'If set to true, indicate that we are dealing with a sound media and that the player will be provided with an XML file of the envelop of the sound. That envelop will be displayed within a Flash object that will replace the QuickTime object. The QuickTime object is still there (to play the sound), but is invisible. If set to true, one have to provide the url_lvl_xml parameter too',
	url_lvl_xml				: 'url of the xml file converted from the lvl one. That conversion is done by the script MakeAudioEnv',
	width					: 'Width of the video (or the Flash display if sound_level is true)'	,
	height					: 'Height of the video (or the Flash display if sound_level is true)'	,
	imageRootURL			: 'Relative URL of the directory where the images are located',	 
	typeMime				: 'Type mime used by the plug-in',
	should_select_all		: 'When Set, all the video is considered as a selection by default (INA demand). This is done only when the plug-in is ready to provide an evaluation of the length of the media',
	config_help				: 'To get the present help instead of the player',
	help					: 'shortcut for config_help',
	name					: 'Name of the plug-in object. Careful !! Not yet fully implemented : movie1 is still here and there in the code.',
	flash_movie_name		: 'Relative path to the flash object, without the suffix e.g. : ow_flash/ow_soundLevel', // 'ow_flash/ow_soundLevel' or 'ow_soundLevel'
	autoplay				: 'Load the video in autoplay mode'	,
	help_panel_target		: 'name of a page object (usually the application panel div), to which the help_panel will be attached (instead of the default container). This is because of IE bug, that does not allow the hiding/showing of the quicktime plug-in when listening to the events',		
	webmasterEmail			: 'Email included in error message... if set, replace orao@opsomai.com within the mes_quicktime_not_available message (tooltip array)',
	language				: '\'en\' or \'fr\' to get tooltips in French or English'	,
	debug_mode				: 'When true, display an additional panel where some debug value are set'	,
	debug_mode2				: 'When true, errors are caughtcaught and displayed in an alert sheet'	,
	advance_jog_shuttle		: 'True => when direct click, the targeted speed is maintained, even after the release release. False => usual physical behaviour : after any interaction, speed is back to 0'	,
	start_the_stepping_after: 'Time before the frame by frame start (after the initial step)',
	stepping_frequency		: 'Time between each frame stepping',

	cc2						: 'QuickTime Detection'	,
	expectedQTversion		: 'Expected Quicktime version (If not there, an message is displayed to invite the downloading of the latest version on Apple web site). The messages that would be displayed are set within the tooltips. <br/>N.B.: A string is expected here, to be compatible with, for instance, \'7.3.2\'.</br>Some clues on how to chose : h264 in  6.6, QT Events (OraoWeb >=2) : from QuickTime 7.2.1, Flash support stopped from QT 7.3.1'		,
	quicktimeDetection		: 'When set to false, no quicktime detection, nor version control is done (\'expectedQTversion\' is then useless). Should be set to false when the application already tests the presence of quicktime',
	simulateQTnotAvailable	: 'For the designer : when set to true, simulate what you get when Quicktime is not installed on the machine, if you want to view what is displayed when QT is not up to date, just use expectedQTversion with a version of QT that does not exist yet. . Of course,  the quicktimeDetection parameter is to be set to true !'	,

	cc3						: 'FullScreen'	,
	popUpFullscreen			: 'When set to false the full screen is done by an adjustment of the main window, and not by the opening of a new window as it is the case for the LNR preset for instance. Most of the projects work with this parameter set to false'	, 
	fullscreen				: 'Should be set to true in the FullScreen template/html page (only useful when popUpFullscreen is true)'	,
	urlOfFullscreenPage		: 'URL of the fullscreen page. In the case of a PHP script that manage both the main page and the fullscreen one, one can use something like : <br> <code>document.location.href.gsub(/[#]/,\'\') +\'&FS=on\'</code><br>N.B. : The gsub is there to remove any # from the URL, because all the links are set to  # and dynamically replaced by onclick calls. Again, only useful when popUpFullscreen is true.',

	cc4						: 'TIME and TIMECODE'	,
	timecode_lag			: 'This value is added to the displayed timecode. A properly formatted timecode is expected : \'hh:mm:ss:ff or hh:mm:ss.ff\'',
	timecode_lag_in_second	: 'If \'timecode_lag\' is set, then it gets the priority and is converted into timecode_lag_in_second, over-wise, one can set the timecode lag directly in second, by setting this property',
	timecode_IN				: 'Timecode of the theoretical beginning of the video (if it could be cropped at any frame) : timecode_IN >= timecode_lag. Default to timecode_lag if not set',
	timecode_OUT			: 'Timecode of the theoretical end of the video (if it could be cropped at any frame) : timecode_OUT <= timecode of the last frame. Default to the timecode of the last frame if not set',
	timecode_with_frame		: 'If true, the frame number are displayed',

	cc5						: 'MOVIE Display mode'	,
	scale					: 'Set the scale of the video. The default value (aspect) keep the aspect ratio and scale up to the size specified by the width and height. The other interesting choice is \'tofit\' that use all the available space (and may therefore change the aspect ratio of the video)'	,
	movie_background_color	: 'Background colour of the area defined by \'width\' and \'height\' parameters, not used to display the movie when the scale is \'aspect\'',

	cc6						: 'GEOMETRY, POSITION,layout (in addition to width and height)'	,
	window_position_x		: 'Distance from the left side of the screen to the left side of the current window. Window position when coming back from a full screen switch (case of the scaling of an unique window)'	,
	window_position_y		: 'Distance from the top side of the screen to the top side of the current window. Window position when coming back from a full screen switch (case of the scaling of an unique window)'	,
	window_default_width	: 'Window (indeed innerHTML : available space for the actual web page) Width when coming back from a full screen switch (case of the scaling of an unique window)'	,
	window_default_height	: 'Window (indeed innerHTML : available space for the actual web page) Height when coming back from a full screen switch (case of the scaling of an unique window)'	,
	minimum_available_width : 'When set,  define the minimum possible width of an orao window. By default, set to the initial window width. To be used mainly when you want to avoid a resizing to crash into a too small window when starting with a window lager that the smallest acceptable one',
	minimum_available_height: 'When set,  define the minimum possible height of an orao window. By default, set to the initial window height. To be used mainly when you want to avoid a resizing to crash into a too small window when starting with a window lager that the smallest acceptable one',
	container_width_after_FS: 'When set, define the Orao container width when back from Full Screen. Only usefull when reopening a player in a window previousely scaled by the user',
	free_lateral_width_in_FS: 'In full screen mode, the video container width will be the available width minus this value'		,
	free_lateral_width		: 'In any other mode than FS, the video container width will be the available width minus this value. If <0 (not set), then free_lateral_width = free_lateral_width_in_FS',
	offset_width			: 'Offset between the the with of a window and its inner html width',
	offset_height			: 'Offset between the the height of a window and its inner html height',
	free_height_above		: 'Space above the player for when one want to book some space above the video, especially in full screen mode. Not to be confused with free_vertical_height.',
	free_vertical_height	: 'Free vertical space booked below the video to let room to the controller',
	position_slider_width	: 'Width of the position slider, in order to be able to set a different one in normal size and full screen mode (different only if the FS is set by pop-up)'	,
	selection_adjust_left	: 'Adjustment of the selection bar to take into account thickness of the cursor and usage of border in the CSS : left = border left',
	selection_adjust_cursor	: 'Adjustment of the selection bar to take into account thickness of the cursor and usage of border in the CSS : cursor width',
	selection_adjust_right	: 'Adjustment of the selection bar to take into account thickness of the cursor and usage of border in the CSS : right = border right',
	controller_panel_height	: 'Height of the controller, in pixel, especially for the full screen mode'	,
	controller_panel_width	: 'Width of the Controller Panel. If not set, then will be set to the width of the video',
	automaticallyAdjustSize	: 'There should be a way to switch off the automatic resizing that was introduced with v3.0.8. So a new paramater is added, defaulting to true : automaticallyAdjustSize',

	cc62						: 'CALL-BACK FUNCTIONS'	,
	onMovieFullScreen		: 'Receive a function that is called when the full screen mode is activated',
	onMovieEndFullScreen	: 'Receive a function that is called when the full screen mode is deactivated (when using window resizing mode)',
	onLoadingUpdate			: 'Receive a function that is called after each check-up of the status of the download. That function receive the percent of file loaded. A value of 100 is sent once when the video is fully loaded)',
	onPlayerReady			: 'Receive a function that is called once the player is ready (plug-in connected to the Oraoweb javascript) with a status Playable or Complete',
	onMovieFinished			: 'Not yet fully tested. Just try it if you think it could be useful. When stable, will receive a function that should be call when the movie reach the end',
	doNothingOnMovieFinished: 'If set to false, urlOfEndImage is displayed when the movie reaches the end. If true, just adjust the position and call onMovieFinished if it exist'	,

	urlOfReplacementImage	: 'URL of the image that is displayed when one switch towards the full screen window'	,
	urlOfEndImage			: 'URL of the image that is displayed when the movie reach the end'	,

	cc7						: 'SOUND SLIDER'	,
	sound_handle_variable	: 'If set to true, it means that the sound handle has a height proportional to the sound value. In that case, the sound_slider_width and sound_slider_height should be properly set too'	,
	sound_slider_height		: 'Height of the Sound Slider (Maximum Height of the Sound Handle)'	,
	sound_slider_width		: 'Width of the Sound Slider'	, 
	
	cc8						: 'Template (especially the Controller one)'	,
	code_controller 		: 'Template for the Controller (See the Containers part here after)',
	code_panel_end 			: 'Template for the panel that is displayed when the video reach the end',
	code_panel_end_FS		: 'Template for the panel that is displayed when the video reach the end, in FullScreen',
	code_end_FS_movie_panel	: 'Template for the panel that is displayed in the main window when a FullScreen window is opened',		
	
	cc9						: 'Hash tables of additional data'	,
	images					: 'Names of the <a href=\"#Buttons\">image files</a> located in the directory set by the imageRootURL',	
	tooltips_fr				: '<a href=\"#Tooltips\">Tooltips and messages</a> in French',
	tooltips_en				: '<a href=\"#Tooltips\">Tooltips and messages</a> in English'
},

config_container					: {
	'ow_id_progress_slider'			: 'Progress Slider',
	'ow_id_timecode'				: 'Timecode',
	'ow_id_sound_slider'			: 'Sound Slider',
//	'ow_id_end_restart_video'		: 'div displayed when the video end',
	'ow_image_end_restart_video'	: 'Default image displayed when the end is reached (See \'code_panel_end\')',
//	'ow_id_wentFS_restart_video'	: 'div displayed when the player switch to new window FS mode',
	'ow_image_wentFS_restart_video'	: 'Default image displayed when the player switch to new window FS mode (See \'code_end_FS_movie_panel\')',

	'ow_bouton_fullscreen'			: 'Go to FullScreen when not, and close the window (or resize down) if already in FS, one tag only for both button',
	
	'ow_bouton_etc'					: 'See the <a href=\"#Buttons\">following list of Buttons and Images</a> for other buttons'
},

config_images					: {
	'ow_bouton_play'				: 'Bouton Start the video',
	'ow_bouton_pause'				: 'Bouton Pause the video',
	'ow_bouton_play_pause'			: 'Bouton Switch between Play and Pause (Not Yet Implemented)',
	'ow_bouton_play_again'			: 'Bouton Start the video again after reaching the end',
	'ow_bouton_fast_rewind'			: 'Bouton Fast Rewind',
	'ow_bouton_fast_forward'		: 'Bouton Fast Forward',
	'ow_bouton_step_rewind'			: 'Bouton Step rewind',
	'ow_bouton_step_forward'		: 'Bouton Step forward',
	'ow_bouton_go_to_beginning'		: 'Bouton Go to the Beginning of the movie',
	'ow_bouton_go_to_end'			: 'Bouton Go to the End of the movie',
	'ow_bouton_fullscreen_open'		: 'Bouton Go to FullScreen when not, and close the window (or resize down) if already in FS, one tag only for both button : ow_bouton_fullscreen',
	'ow_bouton_fullscreen_close'	: 'Bouton Go to FullScreen when not, and close the window (or resize down) if already in FS, one tag only for both button : ow_bouton_fullscreen',
	'ow_bouton_mute_sound'			: 'Bouton Shut Down the sound',				
	'ow_bouton_max_sound'			: 'Bouton Max the sound',
	'ow_bouton_logo_player'			: 'Bouton Player (or Client)\'s logo',	
	'ow_bouton_help'				: 'Bouton Help',
	'ow_logo_quicktime'				: 'logo_qtlogo.gif',	
	'ow_background_player'			: 'Optional : set a background image for the container'		,	
	'ow_background_sound_slider'	: 'Background of the sound slider'							,	
	'ow_bouton_beg_selection'		: 'Setting the beginning of an extract (application side)'	,	
	'ow_bouton_end_selection'		: 'Setting the end of an extract (application side)'		,	
	'ow_bouton_save_selection'		: 'Saving an extract (application side)'					,	
	'ow_bouton_new_selection'		: 'Creating a new selection (application side)'				,	
	'ow_bouton_annotate_selection'	: 'Tagging a extract (application side)'			
},

config_tooltips				: {
	'ow_id_timecode' 				: 'Timecode (HH:mm:ss)',
	'ow_id_timecodeLong' 			: 'Timecode (HH:mm:ss.frame)',
	'ow_id_sound_slider'			: 'Volume sonore',
	'ow_id_progress_slider'			: 'Barre de progression',
	'ow_id_jog_slider'				: 'Jog Shuttle',
	'ow_bouton_play' 				: 'Lance la vidéo',
	'ow_bouton_pause' 				: 'Pause la vidéo',
	'ow_bouton_play_pause' 			: 'Lance ou Pause la vidéo',
	'ow_bouton_play_again'			: 'Relance la vidéo',
	'ow_bouton_fast_rewind' 		: 'Retour Rapide',
	'ow_bouton_fast_forward' 		: 'Avance Rapide',
	'ow_bouton_step_rewind'			: 'Back up one image',
	'ow_bouton_step_forward'		: 'Forward by one image',
	'ow_bouton_go_to_beginning'		: 'Go to the Beginning of the movie',
	'ow_bouton_go_to_end'			: 'Go to the End of the movie',
	'ow_bouton_fullscreen_open'		: 'Ouvre en plein écran',
	'ow_bouton_fullscreen_close'	: 'Ferme la fenêtre',
	'ow_bouton_mute_sound' 			: 'Coupe le son',
	'ow_bouton_max_sound' 			: 'Son au maximum',
	'ow_bouton_left_sound'			: 'Entendre uniquement la piste gauche du son'	,
	'ow_bouton_right_sound'			: 'Entendre uniquement la piste droite du son'	,
	'ow_bouton_logo_player'			: 'Player (or Client)\'s logo',	
	'ow_selection_start_handle'		: 'Extract beginning',
	'ow_selection_end_handle'		: 'Extract end',
	'ow_bouton_help'				: 'Show help screen',

	'mes_help_title'				: 'Help screen title',
	'mes_help'						: 'Help Screen content',
	'mes_copyright_title'			: 'Not really yet used copyright',
	'mes_copyright'					: 'Copyright that is displayed as a tooltip when moving the mouse above the not yet loaded part of the progress slider',

	'mes_plugin_not_yet_ready'		: 'Message displayed when the browser can not reach the QT plug-in',
	'mes_quicktime_not_up_to_date'	: 'Message displayed when QT is installed, but not up to date',
	'mes_quicktime_not_available'	: 'Message displayed when QT is not available',
	'mes_flash_not_available'		: 'Message displayed when Flash is not available or up to date'
},

config_API				: {
	'GoToBegSelection()' 			: 'Go to the beginning of the current selection',
	'GoToEndSelection()' 			: 'Go to the end of the current selection',
	'GoToLongTimeCode(_timecode)'	: 'Goto to the correctly formatted time code (hh:mn:ss:ff) if it is already loaded. Then return true. Return false if that time code was not yet loaded. _timecode should take into account timecode_lag as set in the calling parameters',
	'SetSelection(_tc_beg, _tc_end)': 'Set a new selection by specifying its beginning and its end with two timecode (These timecodes are aware of the timecode_lag value). The video keeps playing if it was playing before. The head is positioned within the selection if necessary when the video is playing. When running SetSelection with a not properly ordered selection (_tc_end < _tc_beg), the function reorder the selection (inverse _tc_beg and _tc_end) and then return -1. It returns 1 when everything went well and 0 when an error occured. It returns -2 when _tc_beg < TCin. It returns -3 when _tc_end < _tc_beg and _tc_end < TCin. It returns -4 when _tc_end > TCout. It returns -5 when _tc_end < _tc_beg and _tc_beg > TCout. And when the user fully mixed up everything, it returns -6 when _tc_end < _tc_beg, _tc_end < TCin and _tc_beg > TCout. Eventually, it returns -10 if _tc_beg is not properly formated and -11 if _tc_end is not properly formated (/^\d{2}:\d{2}:\d{2}(:|\.)\d{2}$/)',
	'UnSetSelection()'				: 'Unset the selection : which translate to using timecode_IN (default to 0) as _tc_beg and timecode_OUT (default to the movie duration) as _tc_end. Then it hides the selection bar',
	'GetCurrentSelectionBeginning()': 'Return the Long timecode of the beginning of the current selection, or timecode_IN if no selection is set',
	'GetCurrentSelectionEnd()': 'Return the Long timecode of the end of the current selection, or timecode_OUT if no selection is set',
	'GetCurrentLongTimeCode()' 		: 'Check (and force) the current position to be within timecode_IN and timecode_OUT. Then <b>return</b> the time code of the displayed frame',
	'SetSelectionAll'				: 'specially used with INA who want to set the default status to \'everything selected in a selection\'. This function is automatically (and at the right time) called when the parameter \'should_select_all\' is set to true. It could  be called again, for instance after a call to UnSetSelection, to avoid issue with a too big \'SetSelection\' when the media is still downloading',
	'DetachMovie()'					: 'Usually, this function is called automatically before the window is closed, in order to free IE memory as IE does not do the work properly (Can\'t wait for Google Chrome !). Could be used if one want to light up the page to display some animation before opening a new page'
},

/********************************************************************/
/*	RELEASES NOTES 													*/
/*						BUGS										*/
/*									TODO							*/
/*												RELEASES NOTES		*/
/********************************************************************/
/*See
 	Make sure the last release note available here match the one defined in the header of this file
	var OW_OraoWeb_version				= '1.0';
	var OW_OraoWeb_version_release_date	= '10/01/08';
*/
releases_notes	: [
	{
		version		: '1.0',
		release		: '10/01/08', 
		description	: '<b>First Major release of OraoWeb</b>',
		url			: '/OraoWeb_DemoOpsis_10/',
		todos_and_bugs	: [
			{priority:5, description:"Multilingual Tip/tool", bug:false},
			{priority:5, description:"Simple to call API", bug:false},
			{priority:5, description:"Fully configurable interface", bug:false},
			{priority:0, description:"", bug:false}					
		]
	},
	{
		version		: '1.1',
		started		: '10/01/08 afternoon',
		release		: '10/01/08 evening', 
		description	: 'Versioning information',
		url			: '/OraoWeb_DemoOpsis_11.zip',
		todos_and_bugs	: [
			{priority:5, description:"position slider lost IE5/PC", bug:true},
			{priority:5, description:"move of some Style info from Prototype SetStyle to CSS file for better IE compatibility", bug:false},
			{priority:0, description:"", bug:false}					
		]
	},
	{
		version		: '1.2',
		release		: '16/01/08', 
		started		: '11/01/08',
		description	: 'Towards Presets, and especially CNRS one',
		url			: '/OraoWeb_CNRS_12.zip',
		todos_and_bugs	: [
			{priority:3, description:"Re-Organise Orao Version in a flatten hierarchy", bug:false},
			{priority:3, description:"ToDo and Bug Lists", bug:false},
			{priority:5, description:"New option : position_slider_width : Width of the position slider, in order to be able to set a different one in normal size and full screen mode", bug:false},
			{priority:5, description:"New option : controller_panel_width : If not set, then will be set to the width of the video", bug:false},
			{priority:3, description:"New option : sound_handle_variable : If set to true, its means that the sound handle as a height proportional to the sound value. In that case, the sound_slider_width and sound_slider_height should be set too", bug:false},
			{priority:5, description:"Preset system (applied to CNRS as a test)", bug:false},
			{priority:3, description:"Play/Pause Button : a unique toggle button for both action", bug:false},
			{priority:4, description:"Pas a pas de la video, Frame by frame forward/rewind", bug:false},
			{priority:3, description:"Go to Beginning / End", bug:false},
			{priority:3, description:"Step backward from the end of the movie was not possible. Fixed", bug:true},
			{priority:4, description:"FastRewind could not be the first action to be asked by the user (it would work only after a start/stop or something similar). Fixed", bug:true},
			{priority:0, description:"", bug:false}					
		]
	}	,
	{
		version		: '1.3',
		release		: '21/01/08', 
		started		: '16/01/08',
		description	: 'INA Preset',
		url			: '/OraoWeb_INA_13.zip',
		todos_and_bugs	: [
			{priority:5, description:"Look INA (et preset associé)", bug:false},
			{priority:3, description:"Addition of the prototip library to display richer tooltips", bug:false},
			{priority:3, description:"Text INA for tooltips", bug:false},
			{priority:3, description:"Help Button", bug:false},
			{priority:3, description:"Logo Button", bug:false},
			{priority:3, description:"Cleaning some visual artefact (sound slider handle, step forward icon)", bug:true},
			{priority:3, description:"Sound not set to the right value after a return trip to FS", bug:true},
			{priority:3, description:'Icone du logo QT non géré par la variable idoine', bug:true},
			{priority:0, description:"", bug:false}					
		]
	}	,
	{
		version		: '1.3.1',
		release		: '23/01/08', 
		started		: '21/01/08',
		description	: 'INA Preset : debug of the first INA release',
		url			: '/OraoWeb_INA_131.zip',
		todos_and_bugs	: [
			{priority:5, description:"INA: 'Times Codes' => 'timecodes' => 'Time Codes'", bug:false},
			{priority:3, description:"End of Movie Panel was still built even when not needed", bug:true},
			{priority:3, description:"INA/CNRS Colour corrections for some icons (?)", bug:true},
			{priority:4, description:"INA Timecode initial (--:--...) on one line ", bug:true},
			{priority:5, description:"Detach the movie (QT plug-in + lots of including div) right before unloading the page, to take into account some memory leaking in IE 6 (to be validated)", bug:true},
			{priority:4, description:"Room for lateral interface in FS switch : the new parameter  <a href=\"#ow_config_property_free_lateral_width_in_FS\">'free_lateral_width_in_FS'</a> can be set such as, in full screen mode, the video container width will be the available width minus this value.", bug:false},								
			{priority:4, description:'Div on the right in FS mode', bug:false},
			{priority:4, description:'Reintroduire la variable de pointage vers le player et tester les commandes au viewer, de l\'exterieur de celui ci', bug:false},
			{priority:0, description:"", bug:false}					
		]
	}	,
	{
		version		: '1.3.2',
		release		: '25/01/08', 
		started		: '24/01/08',
		description	: 'INA Preset : debug 2 of the first INA release',
		url			: '/OraoWeb_INA_132.zip',
		todos_and_bugs	: [
			{priority:3, description:"Re-evaluation of the duration of the movie when the download is completed", bug:true},
			{priority:3, description:"Issue with the resizing", bug:true},
			{priority:3, description:"Set the timecode as soon as the movie is playable", bug:true},
			{priority:0, description:"", bug:false}					
		]
	}	,
	{
		version		: '1.3.3',
		release		: '28/01/08', 
		started		: '28/01/08',
		description	: 'INA Preset : debug 3 of the first INA release',
		url			: '/OraoWeb_INA_133.zip',
		todos_and_bugs	: [
			{priority:3, description:"Switch to prototype 1.6.0.2", bug:false},
			{priority:3, description:"No space between button anymore : they would cause issue with a change of size of the default police by the user + timecode area more tolerant with police size changes", bug:true},
			{priority:0, description:"", bug:false}					
		]
	}	,
	{
		version		: '1.3.4',
		release		: '29/01/08', 
		started		: '29/01/08',
		description	: 'INA Preset : debug 4 of the first INA release',
		url			: '/OraoWeb_INA_134.zip',
		todos_and_bugs	: [
			{priority:3, description:"fullscreen button tooltip", bug:true},
			{priority:0, description:"", bug:false}					
		]
	}	,
	{
		version		: '1.4',
		release		: '29/01/08', 
		started		: '28/01/08',
		description	: 'OPSIS Preset',
		url			: '/OraoWeb_OPSIS_14.zip',
		todos_and_bugs	: [
			{priority:5, description:"Optimisation of window size guestimate (Cf Loic trick). Now the value given by the parameters 	<a href=\"#ow_config_property_window_default_width\">window_default_width</a> and <a href=\"#ow_config_property_window_default_height\">window_default_height</a> are really about innerHTML. They are the exact available space for the actual web page (and not the window)", bug:false},
			{priority:5, description:"OPSIS preset, for the Atelier des Archives", bug:false},
			{priority:0, description:"", bug:false}					
		]
	}	,
	{
		version		: '1.5.1',
		release		: '6/02/08', 
		started		: '31/01/08',
		description	: 'Selection extracts',
		url			: '/OraoWeb_OPSIS_151/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:"Management of selections : <a href=\"#ConfigAPI\">opening of the public API</a>. There are still limitations (See todo), but development may start on the application side", bug:false},
			{priority:5, description:"Full support of <a href=\"#ow_config_property_timecode_lag\">'timecode_lag'</a>, <a href=\"#ow_config_property_timecode_lag_in_second\">'timecode_lag_in_second'</a>, <a href=\"#ow_config_property_timecode_IN\">'timecode_IN'</a>, and <a href=\"#ow_config_property_timecode_OUT\">'timecode_OUT'</a>", bug:false},
			{priority:5, description:"Full support of <a href=\"#ow_config_property_onMovieFullScreen\">'onMovieFullScreen'</a>, <a href=\"#ow_config_property_onMovieEndFullScreen\">'onMovieEndFullScreen'</a> call-back functions", bug:false},
			{priority:5, description:"Re-evaluation of the duration of the movie when the download is completed (Yes, again : there was a bug in the previous debugging of that issue)", bug:true},
			{priority:5, description:"Allow a play right after a backward step, when stating from the end", bug:true},
			{priority:5, description:"Right after the plug-in was launched, the timecode was updated with a value of 0, without taking into account the timecode_lag parameter.", bug:true},
			{priority:4, description:"Update of the timecode after a pause", bug:false},
			{priority:0, description:"", bug:false}					
		]
	}	,
	{
		version		: '1.5.2',
		release		: '6/02/08', 
		started		: '6/02/08',
		description	: 'Selection extracts : Behaviours Limitations',
		url			: '/OraoWeb_OPSIS_152/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:"Gestion des selections : restriction of the fast forward, fast rewind, step forward, step rewind behaviour according to the current selection. Use of QT plug-in restriction", bug:false},
			{priority:5, description:"Two new functions <a href=\"#ConfigAPI\">in the API : 'GetCurrentSelectionBeginning' and 'GetCurrentSelectionEnd'</a>. See <a href=\"ow_template_INA_popup151.html\">the template</a> for an example of their usage", bug:false},
			{priority:5, description:"The sound can be set again directly through the QT plug-in in Safari", bug:true},
			{priority:4, description:'Quicktime detection is now optional (to avoid doing it twice when the calling application does it already). The parameter is <a href=\"#ow_config_property_quicktimeDetection\">\'quicktimeDetection\'</a>, set to true per default, and to false for INA, OPSIS and other presets', bug:false},
			{priority:0, description:""}					
		]
	}		,
	{
		version		: '1.5.3',
		release		: '22/02/08', 
		started		: '19/02/08',
		description	: 'Bug : unset selection when time in and time out not manually defined  version 1.5.3c',
		url			: '/OraoWeb_OPSIS_153/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:"a) When timecode_IN and timecode_OUT are not manually set, the following sequence of calls bring the video to the end: UnSetSelection() GoToBegSelection() PlayTheVideo()", bug:true},
			{priority:4, description:"b) Rajout du typeMime : 'video/mpeg', dans le preset INA", bug:true},
			{priority:4, description:"c) Bug Define End do not set the slider back to the beginning of the selection", bug:true},
			{priority:0, description:""}					
		]
	}			,
	{
		version		: '1.6',
		release		: '13/03/08', 
		started		: '13/08/08',
		description	: 'Last INA modifications before reengineering of the core',
		url			: '/OraoWeb_OPSIS_16/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:"Free_height_above is a new parameter for when one want to book some space above the video, especially in full screen mode. Not to be confused with free_vertical_height which is used when coming back from fullscreen", bug:false},
			{priority:4, description:"INA preset : controller_panel_height preset value for INA was too big, potentially producing a window scrolling bar", bug:true},
			{priority:3, description:"New parameter : onLoadingUpdate : potentially Receive a function that is called after each check-up of the status of the download. That function receive the percent of file loaded. A value of 100 is sent once (and only once) when the video is fully loaded', ", bug:false},
			{priority:3, description:"When passing an mpeg1 file and setting a selection outside of the currently loaded part of the movie, the loading would stop under IE6. This does not happen when the media file is encapsulated into a quicktime qtref, which is the case when a logo is applied within INAcontext', ", bug:true},
			{priority:5, description:"Logo overlapping, not possible with SMIL, done (and checked against) a QTkit script (addLogoQTToMovie) that will produce a quicktime reference to the mpeg movie", bug:false},
			{priority:0, description:""}					
		]
	}				,
	{
		version		: '1.6.1',
		release		: '19/03/08', 
		started		: '14/03/08',
		description	: 'New cursor, Dynamic selection bar, Help Panel ...',
		url			: '/OraoWeb_OPSIS_161/ow_help.html',
		todos_and_bugs	: [
			{priority:3, description:"Sound level was set to 100% by the end of the loading phase", bug:true},
			{priority:5, description:"INA preset : New image for the position handle", bug:false},
			{priority:5, description:"Catching of the click event on the extract bar", bug:false},
			{priority:3, description:"SetSelection behaviour : back to basic : 1) Does NOT modify the playing mode : keep playing if and only if it was playing before the selection 2) Does NOT set the playing position back to the beginning : this is still done on the application side (could be implemented within version 2)", bug:false},
			{priority:4, description:"Dynamic Selection bar : The selection bar now take into account the status of the download. It is no more possible to access the part that is no yet downloaded. There is a need to define a CSS for a new div : ow_navigation_selected_target, in a complement to ow_navigation_selected_extract (Which represent the full selection in the background, even if it is not yet available)", bug:false},
			{priority:4, description:"Help panel updated, with the option to include images in it", bug:false},
			{priority:2, description:"New parameter : simulateQTnotAvailable : For the designer : when set to true, simulate what you get when Quicktime is not installed on the machine, if you want to view what is displayed when QT is not up to date, just use expectedQTversion with a version of QT that does not exist yet. Of course,  the quicktimeDetection parameter is to be set to true !", bug:false},
			{priority:5, description:'Safari loading sequence : sometime, one as too reload the page. Possible Clue : Check that the mime type are properly set both on the viewer and on the server side. The present fix is to check the status of the page after 3s and if an error is returned, to reload the page', bug:true},
			{priority:0, description:"", bug:false}					
		]
	}					,
	{
		version		: '1.6.2',
		release		: '25/03/08', 
		started		: '20/03/08',
		description	: 'Tests adding a logo with ... DIV, CSS z-index, wmode...',
		url			: '/OraoWeb_OPSIS_162/ow_help.html',
		todos_and_bugs	: [
			{priority:3, description:"Not yet appropriate : does not work on FF Mac, and bug on IE", bug:false},
			{priority:0, description:"wmode is promising, but not yet ready. If we were to adopt this option, the position of the logo would have to be adjusted when going to FS", bug:false},
			{priority:0, description:"", bug:false}															
		]
	}
						,
	{
		version		: '2.0',
		release		: '14/4/08', 
		started		: '1/4/08',
		description	: 'New architecture using Apple event, which bring the jog shuttle back...',
		url			: '/OraoWeb_OPSIS_2/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:"Jog Shuttle", bug:false},
			{priority:5, description:"Integration of quicktime plug-in events : getting rid of of two idle loops and diminishing the importance of the last one", bug:false},
			{priority:3, description:'Organisation/optimisation of the loading phase', bug:false},
			{priority:2, description:'The javascript call has now to be done within the container div (as usual, to fix an issue with IE), and there is no more a need to observe a \'dom:loaded\' event : it is now done internally within the player - see the template for details', bug:true},
			{priority:3, description:"The help panel can be attached to a different div than the default container, in order to avoid some bug with IE", bug:true},
			{priority:3, description:'Inclusion of the latest apple ac_quicktime library to include quicktime plug-in', bug:false},
			{priority:0, description:"", bug:false}
		]
	}
						,
	{
		version		: '2.0.1',
		release		: '25/4/08', 
		started		: '16/4/08',
		description	: 'Checking release 0 with template other than INA...',
		url			: '/OraoWeb_OPSIS_201/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:"Anatec = Preset OPSIS + images Anatec + CSS", bug:false},
			{priority:5, description:"Tried to fix a random bug that would see a vibration of the video due to a conflict between a quicktime managed play (SetRate), and a manual Orao Rewind. Please report if you still see that bug", bug:true},
			{priority:3, description:"Replaced a test 'this.rewind_speed < 0' by a the test on this.manual_rewind_timer in various place", bug:false},
			{priority:3, description:"preset OPSIS become METAL and CNRS become OPSIS", bug:false},
			{priority:0, description:"", bug:false}
		]
	}						
						,
	{
		version		: '2.0.2',
		release		: '7/5/08', 
		started		: '12/5/08',
		description	: 'Nettoyage preset par defaut',
		url			: '/OraoWeb_OPSIS_202/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:"2 Presets : OPSIS et OPSIS_MINI", bug:false},
			{priority:5, description:"Reintegration CSS de Loic", bug:true},
			{priority:5, description:"Separation claire OraoWeb / Opsis", bug:false},
			{priority:5, description:"Simplification livraison (css compilés)", bug:false},
			{priority:0, description:"", bug:false}
		]
	}						
						,
	{
		version		: '2.0.3',
		release		: '20/5/08', 
		started		: '20/5/08',
		description	: 'Added Scale option',
		url			: '/OraoWeb_OPSIS_202/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:"Ajout de opts.scale. Par defaut : 'aspect'. Si l'on veut déformer la video (changer son aspect ratio), on utilise 'tofit'. On peut aussi changer l'échelle (2, 3 ...)", bug:false},
			{priority:0, description:"", bug:false}
		]
	}						
						,
	{
		version		: '2.0.4',
		release		: '22/5/08', 
		started		: '22/5/08',
		description	: 'Phase de chargement modifie',
		url			: '/OraoWeb_OPSIS_204/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:"Si les events ne sont pas registred after 5 sec, force the registration manually", bug:true},
			{priority:5, description:"Force the research for a pointer  manually", bug:true},
			{priority:5, description:"Send regularly a virtual event, till everything is started", bug:true},
			{priority:0, description:"", bug:false}
		]
	}						
						,
	{
		version		: '2.0.5',
		release		: '9/6/08', 
		started		: '26/5/08',
		description	: 'Expanding an existing selection',
		url			: '/OraoWeb_OPSIS_205/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:"Unset the QT selection when using the navigation bar (while in pause)", bug:false},
			{priority:5, description:"Resetting the QT selection after each loading update (the selection should always remain within the loaded par)", bug:false},
			{priority:5, description:"Send regularly a virtual event, till everything is started", bug:true},
			{priority:5, description:"Force the call to UpdateChargement  the first time a virtual event is successful initiating the reference to the plug-in", bug:true},
			{priority:0, description:"", bug:false}
		]
	}						
						,
	{
		version		: '2.1',
		release		: '23/6/08', 
		started		: '11/6/08',
		description	: 'Stabilisation de la version 2',
		url			: '/OraoWeb_OPSIS_21/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:"Safari keep reloading when dealing with really big files", bug:true},
			{priority:5, description:"Scale properly fitted movie when going FS", bug:false},
			{priority:0, description:"Added attribute : onPlayerReady : a reference to a function called when the player is ready", bug:false}
		]
	}						
						,
	{
		version		: '2.1.1',
		release		: '3/7/08', 
		started		: '2/7/08',
		description	: 'Modif ControllerINA',
		url			: '/OraoWeb_OPSIS_21/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:"Adding two button/function to set the sound balance (javascript function called)", bug:false},
			{priority:5, description:"Inverted navigation bar colour for INA CSS", bug:false},
			{priority:0, description:"", bug:false}
		]
	}						
						,
	{
		version		: '2.1.2',
		release		: '5/7/08', 
		started		: '5/7/08',
		description	: 'Positionnement relatif de la video dans le cas de IE6',
		url			: '/OraoWeb_OPSIS_21/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:"comment the line // this.container.setStyle({position: 'relative'});  ", bug:false},
			{priority:5, description:"Inverted navigation bar colour for INA CSS", bug:false},
			{priority:0, description:"", bug:false}
		]
	}						
						,
	{
		version		: '3.0.1',
		release		: '20/8/08', 
		started		: '7/8/08',
		description	: 'Version Son (Ina Radio) avec Enveloppe sonore en Flash',
		url			: '/OraoWeb_OPSIS_301/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:"option sound_level to be set to true if one want wavelength representation instead of video (default false)", bug:false},
			{priority:5, description:"Retour par saut sur la ligne principale 12/08", bug:false},
			{priority:5, description:"Cas scale <1  13/08", bug:false},
			{priority:5, description:"Couleurs standards  13/08", bug:false},
			{priority:5, description:"Zoom de la page  19/08", bug:false},
			{priority:0, description:"", bug:false}
		]
	}						
						,
	{
		version		: '3.0.3',
		release		: '21/8/08', 
		started		: '20/8/08',
		description	: 'the bugs arrive',
		url			: '/OraoWeb_OPSIS_303/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:"When back from FS in FF, the sound stop !", bug:true},
			{priority:5, description:"Zoom de la page  20/08", bug:false},
			{priority:5, description:"Information de progrès du chargement  20/08", bug:false},
			{priority:5, description:"Mode FS in IE  21/08", bug:true},
			{priority:0, description:"", bug:false}
		]
	}						
						,
	{
		version		: '3.0.4',
		release		: '26/8/08', 
		started		: '22/8/08',
		description	: 'finishing main concepts',
		url			: '/OraoWeb_OPSIS_304/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:"Display selection sprites in Flash (parts not selected)", bug:false},
			{priority:5, description:"New parameter : should_select_all ask the player to select all the media once its length is known. Mostly an INA demands to match the colour scheme of the QT-Interactive version of Orao", bug:false},
			{priority:0, description:"", bug:false}
		]
	}						
						,
	{
		version		: '3.0.5',
		release		: '4/9/08', 
		started		: '1/9/08',
		description	: 'Debugging phase',
		url			: '/OraoWeb_OPSIS_305/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:"Flash : The right block were not big enough for when scale <1", bug:true},
			{priority:3, description:"Sometimes, when the media is in cache, the Flash object does not receive loading update or selection calls 1/9/08", bug:true},
			{priority:5, description:"Sometimes, the 'Complete' event is simply not sent. So one have to round the loading to 1000 when reaching a level above 980 1/9/08", bug:true},
			{priority:5, description:"autoplay mode would sometime not start. Added a check 1s after the plug-in is ready 2/9/08", bug:true},
			{priority:4, description:"Addition to the public API :  DetachMovie() to clean a page : free the DOM from the Quicktime object and every panel related to the OraoWeb player 2/9/08", bug:false},
			{priority:3, description:"Introduction of various try/catch in place detected by INA/Pierre the catch are activated when the new parameter debug_mode2 is set to true 3/9/08", bug:false},
			{priority:4, description:"fix the possible and inappropriate initial use of 'this.theVideo' : this is now not done until plugin_status == ('Loading' || 'Playable' || 'Complete') 3/9/08", bug:true},
			{priority:0, description:"", bug:false}
		]
	}
						,
	{
		version		: '3.0.6',
		release		: '12/9/08', 
		started		: '4/9/08',
		description	: 'Documentation update',
		url			: '/dev3/ow_help.html',
		todos_and_bugs	: [
			{priority:4, description:"Clean up the documentation (and small update of the main CSS) 4-5/9/08", bug:false},
			{priority:4, description:"Tested and validated the callback function :\'onMovieFinished\' 5/9/08", bug:false},
			{priority:4, description:"When reaching the end of a segment/extract, then using the flash interface to move around, the play button was sometime deactivated (when GoToPercent is used, we set reach_the_end to false) 5/9/08", bug:false},
			{priority:2, description:"Bug repport to Apple : Bug ID# 6203295 : Safari display an error message that is not appropriate 8/9/08", bug:false},
			{priority:5, description:'Jog Shuttle : back to a classic behaviour (when released after a simple click, back to speed = 0) : this can be obtained by setting the new parameter \'advance_jog_shuttle\' to false 8/9/08', bug:false},
			{priority:3, description:'Dealing with the error coming from the sound level file not being a clean XML one : right now, the only path I could propose would be to change the character set used as binary encoding of the level values. That would imply more work, without a real benefit (only firefox display a error message, but without any bad consequences) 8/9/08', bug:true},
			{priority:3, description:'Keyboard interaction with the player. Not fully convincing yet : depend on the player, but at the same time, this is not yet set as an expressed requierement in any of opsomai project => Standby 9/9/08', bug:false},
			{priority:3, description:'Test with Google chrome : it works ! (except for the resizing of the page, which is not yet possible in the beta version of Chrome) 9/9/08', bug:false},
			{priority:3, description:'Test RC of next version of QuickTime : now an official release : Version 7.5.5 (990.7) => OK on Mac and PC (Vista) 12/9/08', bug:false},
			{priority:3, description:'Usage of \'#\' in href attribute see some pages scroll. This was one of the resaon why IE would present a very strange bahaviour, refusing to load a page containing the browser (see the main reason at : <a href="http://support.microsoft.com/default.aspx/kb/927917" title="BUG&#58; Error message when you visit a Web page or interact with a Web application in Internet Explorer&#58; &#34;Operation aborted&#34;">http://support.microsoft.com/default.aspx/kb/927917</a> ). As a result of that bug, the following advice is given : OUTSIDE of the empty DIV "container" and, mainly for the pleasure of that poor IE, as close as possible to the closing /body, insert the javascript code : declare a variable <code>OW_Player</code> (*), declare an hashtable of parameters, and then instantiate the object (with the id of the div container and the hashtable of parameters) and put its reference into the OW_Player variable. 12/9/08 ', bug:true},
			{priority:3, description:'Added SetSelectionAll to the public API 12/9/08', bug:false},			
			{priority:0, description:"", bug:false}
		]
	}
						,
	{
		version		: '3.0.7',
		release		: '16/9/08', 
		started		: '15/9/08',
		description	: 'Step by Step, and advance button behaviour',
		url			: '/stable3/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:'Brought back from QTI version of Orao : maintaining frame by frame key will induce 4 jump per second 16/9/08', bug:false},
			{priority:3, description:'Visual feedback about locked and maintained pressed button. A second click on a locked button unlock it (fast forward and rewind) 16/9/08', bug:false},			
			{priority:3, description:'If you press the "shift" key at the same time you click on the help button, you get an alert with Orao version number ! Isn\'t that a coool trick :-) 16/9/08', bug:false},			
			{priority:3, description:'Big modification within the launching phase : document.observe(\'dom:loaded\', this.LaunchABitLater.bind(this)); is replaced by a straight LaunchABitLater ... to be checked and controlled ! 16/9/08', bug:false},			
			{priority:3, description:'Test for Gaumont : it is possible to create a player after the loading phase, especially, after a clic on an image 16/9/08', bug:false},			
			{priority:3, description:'Addition of the advance button behaviour to OPSIS/GAUMONT. Make sure a boutons_pressed is avalaible in your image directory !', bug:false},			
			{priority:0, description:"", bug:false}
		]
	}
						,
	{
		version		: '3.0.8',
		release		: '23/9/08', 
		started		: '18/9/08',
		description	: 'Conitunous window adjustement',
		url			: '/dev3/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:'Adjust the size of the player to the size of the windown. Dealing with a manual resizing of a window. 18-23/9/08', bug:false},
			{priority:0, description:"", bug:false}
		]
	}
						,
	{
		version		: '3.0.9',
		release		: '26/9/08', 
		started		: '23/9/08',
		description	: 'Various',
		url			: '/dev3/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:'Quictime detection 23/9/08', bug:true},
			{priority:3, description:'Reported to Apple : When fast rewarding (whatever the speed) sound stop after 1s'},
			{priority:0, description:"", bug:false}
		]
	}
						,
	{
		version		: '3.1',
		release		: '3/10/08', 
		started		: '26/9/08',
		description	: 'Big Cleaning ( JSLint : http://www.jslint.com/ ) and Minification ( Packer : http://dean.edwards.name/packer/ ) of the code, and official release for the the continuous adjustement to the window size',
		url			: '/stable3/ow_help.html',
		todos_and_bugs	: [
			{priority:3, description:'a : cleaning \\ : replaced by \' + \' in multiple line expressions', bug:false},
			{priority:3, description:'b : cleaning [\'\'] : replaced by .', bug:false},
			{priority:3, description:'c : cleaning for in loop', bug:false},
			{priority:3, description:'Minification using Packer and yuicompressor-2.3.5. yuicompressor for the CSS file and either Packer (OW_Player_minifie.js) or yuicompressor (OW_Player_minifie_yui.js) for javascript. Packer is more efficient, bug only available online in version 3', bug:false},
			{priority:3, description:'Container size evaluation deported to the first window fitting 3/10/08', bug:true},
			{priority:3, description:'Update to prototype 1.6.0.3 standard ; the extension of the PeriodicalExecuter class is now done from within the OW_Player library 3/10/08', bug:true},
			{priority:3, description:'better management of the xml ajax request which read the sound envelopp shape : an error message is displayed when the url is not correct (not targetting a file or targetting a file on a different serveur than the source of the ajax call) and the \'debug_mode2\' parameter is set to true 3/10/08', bug:true},
			{priority:0, description:"", bug:false}
		]
	}
						,
	{
		version		: '3.1.1',
		release		: '20/10/08', 
		started		: '20/10/08',
		description	: 'GoToLongTimeCode',
		url			: '/dev3/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:'GoToLongTimeCode(_timecode)	: Goto to the correctly formatted time code (hh:mn:ss:ff) if it is already loaded. Then return true. Return false if that time code was not yet loaded. _timecode should take into account timecode_lag as set in the calling parameters', bug:false},
			{priority:0, description:"", bug:false}
		]
	}
						,
	{
		version		: '3.1.2',
		release		: '24/10/08', 
		started		: '24/10/08',
		description	: 'Deal with bad TCout',
		url			: '/dev3/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:'Deal with obiousely badly set timecode_OUT (if timecode_IN >= timecode_OUT then deal itself with the timecode_OUT)', bug:false},
			{priority:0, description:"", bug:false}
		]
	}
						,
	{
		version		: '3.1.3',
		release		: '13/11/08', 
		started		: '27/10/08',
		description	: 'Integration multipage de gaumont : persistance de la taille de la fenetre entre chaque reouverture',
		url			: '/dev3/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:'New parameter, to differentiate FS and non FS : free_lateral_width : In any other mode than FS, the video container width will be the available width minus this value. If <0 (not set), then free_lateral_width = free_lateral_width_in_FS', bug:false},
			{priority:5, description:'New parameter, minimum_available_width : When set,  define the minimum possible width of an orao window. By default, set to the initial window width. To be used mainly when you want to avoid a resizing to crash into a too small window when starting with a window lager that the smallest acceptable one', bug:false},
			{priority:5, description:'New parameter, minimum_available_height: When set,  define the minimum possible height of an orao window. By default, set to the initial window height. To be used mainly when you want to avoid a resizing to crash into a too small window when starting with a window lager that the smallest acceptable one', bug:false},
			{priority:5, description:'container_width_after_FS: When set, define the Orao container width when back from Full Screen. Only usefull when reopening a player in a window previousely scaled by the user', bug:false},
			{priority:3, description:'SetSelection : after the selection is set, the position is set to the beginning of the selection, if possible', bug:false},
			{priority:3, description:'Modification to the help text for the Opsis preset', bug:false},
			{priority:0, description:"", bug:false}
		]
	}
						,
	{
		version		: '3.1.4',
		release		: '26/12/08', 
		started		: '24/11/08',
		description	: 'Lost of video timecode synchronisation',
		url			: '/dev3/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:'When one clic on the video to stop it, the timecode was not updated', bug:false},
			{priority:4, description:'Quicktime SetSelection was done before checking if one had to reposition the javascript header. Now it is done at the end of any SetSelection', bug:false},
			{priority:3, description:'3.1.4e Bug Gaumont 38', bug:false},
			{priority:0, description:"", bug:false}
		]
	}
						,
	{
		version		: '3.2',
		release		: '30/12/08', 
		started		: '30/12/08',
		description	: 'milestone : Gaumont + INA',
		url			: '/dev3/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:'Checked that Gaumont work did not disturb INA templates', bug:false},
			{priority:0, description:"", bug:false}
		]
	}
						,
	{
		version		: '3.2.1',
		release		: '8/1/09', 
		started		: '8/1/09',
		description	: 'New option : no automatic resizing',
		url			: '/dev3/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:'There should be a way to switch off the automatic resizing that was introduced with v3.0.8. So a new paramater is added, defaulting to true : automaticallyAdjustSize', bug:false},
			{priority:0, description:"", bug:false}
		]
	}
						,
	{
		version		: '3.2.2',
		release		: '28/1/09', 
		started		: '28/1/09',
		description	: 'SetSelection return the status of the request',
		url			: '/dev3/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:'When running SetSelection with a not properly ordered selection (_begTC < _endTC), the function reorder the selection (inverse _begTC and _endTC) and then return -1. It return 1 when everything went well and 0 when an error occured', bug:false},
			{priority:0, description:"", bug:false}
		]
	}
						,
	{
		version		: '3.2.3',
		release		: '28/1/09', 
		started		: '28/1/09',
		description	: 'SetSelection checks if the entered values are properly formated',
		url			: '/dev3/ow_help.html',
		todos_and_bugs	: [
			{priority:5, description:'SetSelection returns -10 if _tc_beg is not properly formated and -11 if _tc_end is not properly formated (/^\d{2}:\d{2}:\d{2}(:|\.)\d{2}$/)', bug:false},
			{priority:0, description:"", bug:false}
		]
	}
],




todos	: [
	{priority:1, description:'Pre-loading of Images'},
	{priority:1, description:"Sound level propagate from first screen to full screen and between videos (cookies)"},
	{priority:1, description:"Tooltip different pour debut et fin suivant context d'extrait ou non"},
	{priority:1, description:"Tooltip different pour play/pause suivant context"},
	{priority:1, description:"Allows more than one video in one page (not easy !!!)"},
	{priority:0, description:"Check that controller_panel_width is greater than any inside element ( e.g. : position_slider_width)"},
	{priority:0, description:""}
],
bugs	: [
	{priority:1, description:'When trying to measure the correct available space in IE, it introduces a lateral slider and therefore a bug in the measurement!'},
	{priority:1, description:'VP : When switching to a new sequence/extract, the time it takes is proportional to the length of the extract, or at least, it is not constant (See http://opsisnew.opsomai.eu/)'},
	{priority:2, description:'VP : issue with a big file : the player doesn\'t seems to use the right value for the duration of the movie : http://atelierdesarchives.opsismedia.com/media/visionnage/1201883779.18909000/KADAV384_VIS1421_1437.mp4'},
	{priority:1, description:'Bug to report : a video added to QT plug-in through a Set URL would not send any correct cookie (the session would be broken)'},
	{priority:0, description:'bug'}
],

					
// debug_feedback				: '<a id="debuglance1" href="#" id="debuglance1">Lance1</a> // <a id="debuglance2" href="#" id="debuglance2">Lance2</a> // <a id="debuglance3" href="#" id="debuglance3">Lance3</a><br>d1(<span id="debug1">-1</span>) / d2(<span id="debug2">-1</span>)  / d3(<span id="debug3">-1</span>)  / dPos(<span id="debugPos">-1</span>)  / dChar(<span id="debugChar">-1</span>)  / dProb(<span id="debugProb">-1</span>)',
debug_feedback				: '<br>d1(<span id="debug1">-1</span>) / d2(<span id="debug2">-1</span>)  / d3(<span id="debug3">-1</span>)  / dPos(<span id="debugPos">-1</span>)  / dChar(<span id="debugChar">-1</span>)  / dProb(<span id="debugProb">-1</span>)',
debug1						: 0 ,
debug2						: 0	,
debug3						: 0	,
debugPos					: 0	,
debugChar					: 0	,
debugProb					: 0 

}	);
