maj client
authorymh <ymh.work@gmail.com>
Wed, 01 Dec 2010 16:43:56 +0100
changeset 125 849bbb496fe6
parent 124 6de7f434618a
child 126 fc3599ebed15
maj client
client/player/src/js/LdtPlayer.js
client/player/src/js/LdtPlayer.min.js
--- a/client/player/src/js/LdtPlayer.js	Wed Dec 01 16:29:15 2010 +0100
+++ b/client/player/src/js/LdtPlayer.js	Wed Dec 01 16:43:56 2010 +0100
@@ -1,4 +1,4 @@
-/* 
+/* 
  * 	
  *	Copyright 2010 Institut de recherche et d'innovation 
  *	contributor(s) : Samuel Huron 
@@ -17,13 +17,11 @@
  *	knowledge of the CeCILL-C license and that you accept its terms.
 */
 
-
-
-
 if(window.__IriSP === undefined ){ var __IriSP={};}
 
-// Player Configuration  
-__IriSP.config = {
+// Player Configuration 
+__IriSP.config = undefined;
+__IriSP.configDefault = {
 		metadata:{
 			format:'cinelab',
 			src:'http://exp.iri.centrepompidou.fr/franceculture/franceculture/ldt/cljson/id/ef4dcc2e-8d3b-11df-8a24-00145ea4a2be',
@@ -39,7 +37,24 @@
 		},
 		player:{
 			type:'jwplayer',
-			src:'../res/swf/player.swf'
+			src:'../res/swf/player.swf',
+			params:{
+				allowfullscreen:"true", 
+				allowscriptaccess:"always",
+				wmode:"transparent"
+			},
+			flashvars:{
+				streamer:"streamer",
+				file:"file", 
+				live:"true",
+				autostart:"true",
+				controlbar:"none",
+				playerready:"__IriSP.playerReady"
+			},
+			attributes:{
+				id:"Ldtplayer1",  
+				name:"Ldtplayer1"
+			}
 		},
 		module:null
 	};
@@ -57,8 +72,7 @@
 "\n<a onclick=\"__IriSP.MyApiPlayer.share('delicious');\" title='partager avec delicious'><span class='share shareDelicious'>&nbsp;</span></a>"+		
 "\n<a onclick=\"__IriSP.MyApiPlayer.share('facebook');\" title='partager avec facebook'> <span class='share shareFacebook'>&nbsp;</span></a>"+
 "\n<a onclick=\"__IriSP.MyApiPlayer.share('twitter');\" title='partager avec twitter'>  <span class='share shareTwitter'>&nbsp;</span></a>"+
-"\n<a onclick=\"__IriSP.MyApiPlayer.share('myspace');\" title='partager avec Myspace'>  <span class='share shareMySpace'>&nbsp;</span></a>"+
-"\n<a onclick=\"__IriSP.MyApiPlayer.share('jamespot');\" title='partager avec JamesPot'>  <span class='share shareJamesPot'>&nbsp;</span></a>";
+"\n<a onclick=\"__IriSP.MyApiPlayer.share('myspace');\" title='partager avec Myspace'>  <span class='share shareMySpace'>&nbsp;</span></a>";
 
 // Official instance - to refactor ?
 __IriSP.MyLdt 		= null;
@@ -68,8 +82,8 @@
 
 // genral var (old code) - to refactor 
 __IriSP.Durration		= null;
-__IriSP.playerLdtWidth= null;
-__IriSP.playerLdtHeight= null;
+__IriSP.playerLdtWidth	= null;
+__IriSP.playerLdtHeight	= null;
 
 	
  
@@ -77,7 +91,26 @@
 
 __IriSP.init = function (config){
 
-		__IriSP.config 			 = config;
+		
+		if(config === null){
+		
+			__IriSP.config 			 = __IriSP.configDefault;
+			
+		} else {
+			
+			__IriSP.config 			 = config;
+			
+			
+
+			if (__IriSP.config.player.params == null){
+			__IriSP.config.player.params = __IriSP.configDefault.player.params;}
+			
+			if (__IriSP.config.player.flashvars == null){
+			__IriSP.config.player.flashvars = __IriSP.configDefault.player.flashvars;}
+			if (__IriSP.config.player.attributes == null){
+			__IriSP.config.player.attributes = __IriSP.configDefault.player.attributes;}
+		}
+		
 		var metadataSrc 		 = __IriSP.config.metadata.src;
 		var guiContainer		 = __IriSP.config.gui.container;
 		var guiMode				 = __IriSP.config.gui.mode;
@@ -85,7 +118,6 @@
 		// Localize jQuery variable
 		__IriSP.jQuery = null;
 
-
 		/******** Load jQuery if not present *********/
 		if (window.jQuery === undefined || window.jQuery.fn.jquery !== '1.4.2') {
 			var script_tag = document.createElement('script');
@@ -201,7 +233,7 @@
 				/******* Load Metadata *******/
 				
 				__IriSP.jQuery.ajax({
-					  dataType: 'jsonp',
+					  dataType: __IriSP.config.metadata.load,
 					  url:metadataSrc,
 					  success : function(json){
 					  
@@ -294,6 +326,7 @@
 		
 		// AUDIO  */
 		// PB dans le html : ; 
+		if(__IriSP.config.gui.mode=="radio"){
 		__IriSP.jQuery(  "<div id='Ldt-Root'>\n"+
 			"	<div id='Ldt-PlaceHolder'>\n"+
 			"		<a href='http://www.adobe.com/go/getflashplayer'>Get flash</a> to see this player	\n"+
@@ -335,9 +368,54 @@
 			//"<div id='Ldt-Tags'> Mots clefs : </div>"+
 			"</div>"+
 			"<div id='Ldt-output'></div>").appendTo("#"+__IriSP.config.gui.container);
+		} else if(__IriSP.config.gui.mode=="video") {
+		
+			__IriSP.jQuery(  "<div id='Ldt-Root'>\n"+
+			"	<div id='Ldt-PlaceHolder'>\n"+
+			"		<a href='http://www.adobe.com/go/getflashplayer'>Get flash</a> to see this player	\n"+
+			"	</div>\n"+
+			"	<div id='Ldt-controler' class='demo'>\n"+
+			"		<div class='Ldt-Control1' >\n"+
+			"			<button id='ldt-CtrlPlay' onclick='__IriSP.MyApiPlayer.play()'>Lecture / Pause </button>\n"+
+			"			<button id='ldt-CtrlNext' onclick='__IriSP.MyLdt.nextAnnotation()'>Suivant</button>\n"+
+			"		</div>\n"+
+			"		<div id='Ldt-Annotations' class='ui-slider'>\n"+
+			"			<div id='slider-range-min'></div>\n"+
+			"	</div>\n"+
+			"		<div class='Ldt-Control2'>\n"+
+			"			<button id='ldt-CtrlLink'> Partager </button>\n"+
+			"			<button id='ldt-CtrlSound' onclick='__IriSP.MyApiPlayer.mute()'>Sound</button>\n"+
+			"		</div>\n"+
+			"  <div class='cleaner'>&nbsp\;</div> \n"+
+			"  <div id='Ldt-Show-Arrow-container'>\n"+
+			"  	<div id='Ldt-Show-Arrow'> </div>\n"+
+			"  </div>\n"+
+			"</div>\n"+
+			"<div>\n"+
+			" <div id='ldt-Show'> </div>\n"+
+			"	<div id='Ldt-ShowAnnotation-audio' class='demo' >\n"+
+			"		<div id='Ldt-SaTitle'></div>\n"+
+			"		<div id='Ldt-SaDescription'></div>\n"+
+			" 		<div class='cleaner'><!--&nbsp\;--></div>\n"+
+			" </div>\n"+
+			" <div id='Ldt-SaKeyword'>\n"+
+			" <div id='Ldt-SaKeywordText'>  </div>\n"+
+			" <div class='cleaner'></div>\n"+
+			" <div id='Ldt-SaShareTools'>\n"+
+			" \n"+
+			" "+__IriSP.LdtShareTool+"\n"+
+			" \n"+
+			"  </div>\n"+
+			" <div class='cleaner'></div>"+
+			"</div>  "+
+			//"<div id='Ldt-Tags'> Mots clefs : </div>"+
+			"</div>"+
+			"<div id='Ldt-output'></div>").appendTo("#"+__IriSP.config.gui.container);
+		
+		}
+		
 		
 		__IriSP.trace("__IriSP.createHtml","end");
-		
 		__IriSP.jQuery("#Ldt-Annotations").width(width-(75*2));
 		__IriSP.jQuery("#Ldt-Show-Arrow-container").width(width-(75*2));
 		__IriSP.jQuery("#Ldt-ShowAnnotation-audio").width(width-10);
@@ -393,7 +471,7 @@
 		//__IriSP.jQuery("#Ldt-Root").css('display','visible');
 		__IriSP.trace("__IriSP.createInterface",width+","+height+","+duration+",");
 		
-		 __IriSP.jQuery("#Ldt-ShowAnnotation").click(function () { 
+		__IriSP.jQuery("#Ldt-ShowAnnotation").click(function () { 
 			 //__IriSP.jQuery(this).slideUp(); 
 		});
 
@@ -472,17 +550,25 @@
 		
 		__IriSP.MyApiPlayer		= this;
 		
-		__IriSP.createPlayer(width,height,this.url,this.duration,this.streamerPath,this.MySwfPath);
+		__IriSP.createPlayer(this.url,this.streamerPath);
 		__IriSP.trace("__IriSP.APIplayer","__IriSP.createPlayer");
+	
+	//__IriSP.config.player
+	/*
+	- dailymotion  // &enableApi=1&chromeless=1
+	- youtube 
+	- html5
+	- flowplayer 
+	- jwplayer
+	*/
 		
 }
 __IriSP.APIplayer.prototype.ready = function(player){
 
 	//__IriSP.trace("__IriSP.APIplayer.prototype.APIpReady"," __IriSP.createInterface");
 	__IriSP.createInterface(this.width,this.height,this.duration);
-	__IriSP.trace("__IriSP.APIplayer.prototype.APIpReady","END  __IriSP.createInterface");
+	//__IriSP.trace("__IriSP.APIplayer.prototype.APIpReady","END  __IriSP.createInterface");
 
-	
 	// hashchange EVENT
 	if (window.addEventListener){
 	
@@ -521,14 +607,36 @@
 }
 __IriSP.APIplayer.prototype.play  = function(){
 	this.hashchangeUpdate = true;
-	__IriSP.player.sendEvent('PLAY');
+	//__IriSP.trace("__IriSP.config.player.type",__IriSP.config.player.type);
+	if(__IriSP.config.player.type=='jwplayer'){
+	
+		__IriSP.player.sendEvent('PLAY');
+		
+	} else if(__IriSP.config.player.type=='dailymotion' 
+			  || __IriSP.config.player.type=='youtube') {
+			  
+		var status = __IriSP.player.getPlayerState();
+		__IriSP.trace("__IriSP.APIplayer.prototype.play.status",status);
+		if (status!=1){
+			__IriSP.player.playVideo();
+		}else{
+			__IriSP.player.pauseVideo();
+		}
+	}
 }
 __IriSP.APIplayer.prototype.mute  = function(){
 	__IriSP.player.sendEvent('MUTE');
+	
+	//alert(__IriSP.jQuery(".ui-icon-volume-on").css("background-position-x"));
+	if (__IriSP.jQuery(".ui-icon-volume-on").css("background-position")=="-144px -160px"){
+		__IriSP.jQuery(".ui-icon-volume-on").css("background-position","-130px -160px");
+	} else {
+		__IriSP.jQuery(".ui-icon-volume-on").css("background-position","-144px -160px");
+	}
 }
 __IriSP.APIplayer.prototype.share = function(network){
 
-	var MyMessage = "Je regarde :";
+	var MyMessage = encodeURIComponent("J'écoute Les Retours du Dimanche : ");
 	var MyURLNow = window.location.href;
 	var shareURL;
 	//alert(network+" : "+MyURLNow);
@@ -546,10 +654,17 @@
 			//alert(network+" non actif pour l'instant : "+MyURLNow);
 	}
 	
-	window.location.href = shareURL+encodeURIComponent(MyURLNow);
+	window.open(shareURL+encodeURIComponent(MyURLNow));
+	//window.location.href = shareURL+encodeURIComponent(MyURLNow);
 }
 __IriSP.APIplayer.prototype.seek  = function (time){
-	__IriSP.player.sendEvent('SEEK', time);
+	__IriSP.trace("__IriSP.APIplayer.prototype.seek",time);
+	if(__IriSP.config.player.type=='jwplayer'){
+		__IriSP.player.sendEvent('SEEK', time);
+	} else if(__IriSP.config.player.type=='dailymotion'
+			|| __IriSP.config.player.type=='youtube') {
+		__IriSP.player.seekTo(time);
+	}
 	this.changePageUrlOffset(time);
 }	
 __IriSP.APIplayer.prototype.update = function (time){
@@ -589,48 +704,172 @@
 }
 
 
-
 /* CODE SPECIAL JW PLAYER  creation + listener */
 
 __IriSP.currentPosition 	= 0; 
 __IriSP.currentVolume   	= 50; 
-__IriSP.player 			= null;
-__IriSP.startPosition 	= null;
+__IriSP.player 				= null;
+__IriSP.startPosition 		= null;
+
+
+
+__IriSP.createPlayer = function (url,streamerPath) {
 
-__IriSP.createPlayer = function (width,height,url,duration,streamerPath,MySwfPath) {
 
+	if(__IriSP.config.player.type=='dailymotion'){
+		__IriSP.config.player.src = __IriSP.config.player.src+"&chromeless=1&enableApi=1";
+	} else if (__IriSP.config.player.type=='youtube'){
+		__IriSP.config.player.src = __IriSP.config.player.src+"&enablejsapi=1&version=3";
+	}
+	
 	__IriSP.trace("__IriSP.createPlayer","start");			
 	
-	__IriSP.myUrlFragment = url.split(streamerPath);
-	var file = __IriSP.myUrlFragment[1];
-	var streamer = streamerPath;
+	__IriSP.myUrlFragment = url.split(streamerPath);	
+	__IriSP.config.player.flashvars.streamer =	streamerPath;
+	__IriSP.config.player.flashvars.file =	__IriSP.myUrlFragment[1];
+	
+	var flashvars 		  = __IriSP.config.player.flashvars;
+	var params 			  = __IriSP.config.player.params;
+	var attributes 		  = __IriSP.config.player.attributes;
 	
-	var flashvars = {
-		streamer:streamer,
-		file:file, 
-		live:"true",
-		autostart:"true",
-		controlbar:"none",
-		playerready:"__IriSP.playerReady"
-	}
-
-	var params = {
-		allowfullscreen:"true", 
-		allowscriptaccess:"always",
-		wmode:"transparent"
-	}
-
-	var attributes = {
-		id:"Ldtplayer1",  
-		name:"Ldtplayer1"
-	}
+	__IriSP.trace(
+				  "__IriSP.createPlayer",
+				  "SWFOBJECT src:"+
+				  __IriSP.config.player.src+
+				  " " +__IriSP.config.gui.width+
+				  " " +__IriSP.config.gui.height
+				  );
 	
-	__IriSP.trace("__IriSP.createPlayer","SWFOBJECT src:"+__IriSP.config.player.src+" " +width+" "+height);
-	swfobject.embedSWF(__IriSP.config.player.src, "Ldt-PlaceHolder", width, height, "9.0.115", false, flashvars, params, attributes);
-
+	swfobject.embedSWF(
+						__IriSP.config.player.src,
+						"Ldt-PlaceHolder",
+						__IriSP.config.gui.width,
+						__IriSP.config.gui.height,
+						"9.0.115",
+						false,
+						flashvars,
+						params,
+						attributes
+					);
+	
 	// need a methode to 
 	// re execute if this swf call does'nt work 
 }
+
+/* API DAILYMOTION 	*/
+onDailymotionPlayerReady = function (playerid){
+
+	//alert(playerid);
+	__IriSP.player = document.getElementById(__IriSP.config.player.attributes.id);
+	__IriSP.MyApiPlayer.ready(__IriSP.player);
+	
+	var url = document.location.href;
+	var time = __IriSP.retrieveTimeFragment(url);
+	__IriSP.startPosition = time;
+	__IriSP.DailymotionAddListeners();	
+	
+	__IriSP.MyApiPlayer.ready(playerid);
+}
+__IriSP.DailymotionAddListeners = function () {
+	if (__IriSP.player) { 
+		__IriSP.trace("__IriSP.addListeners","ADD  Listener ");
+		//__IriSP.player.addEventListener("onStateChange", "__IriSP.DailymotionPositionListener");
+		setTimeout("__IriSP.DailymotionPositionListener()",100);
+		__IriSP.DailymotionPositionListener();
+		__IriSP.player.addModelListener("VOLUME", "__IriSP.volumeListener");
+		//__IriSP.player.addModelListener('STATE', '__IriSP.stateMonitor');
+	} else {
+		__IriSP.setTimeout("__IriSP.DailymotionAddListeners()",100);
+	}
+}
+__IriSP.DailymotionPositionListener = function() { 
+	
+	__IriSP.currentPosition = __IriSP.player.getCurrentTime();
+	//__IriSP.trace("__IriSP.DailymotionPositionListener",__IriSP.currentPosition);
+	//__IriSP.trace("__IriSP.currentPosition",__IriSP.currentPosition);
+	
+	__IriSP.jQuery("#slider-range-min").slider("value",__IriSP.currentPosition);
+	__IriSP.jQuery("#amount").val(__IriSP.currentPosition+" s");
+	// afficher annotation 
+	/*__IriSP.MyLdt.checkTime(__IriSP.currentPosition);
+	*/
+	
+	setTimeout("__IriSP.DailymotionPositionListener()",10);
+}
+
+/* API YOUTUBE 	*/
+onYouTubePlayerReady= function (playerid){
+
+	var url = document.location.href;
+	var time = __IriSP.retrieveTimeFragment(url);
+	__IriSP.player = document.getElementById(__IriSP.config.player.attributes.id);
+	__IriSP.startPosition = time;
+	
+	__IriSP.MyApiPlayer.ready(__IriSP.player);
+	
+	__IriSP.MyApiPlayer.seek(time);
+	__IriSP.MyApiPlayer.play();
+	
+	
+	__IriSP.YouTubeAddListeners();	
+	__IriSP.trace("onYouTubePlayerReady=",time);
+	//__IriSP.MyApiPlayer.ready(playerid);
+}
+__IriSP.YouTubeAddListeners = function () {
+	if (__IriSP.player) { 
+		__IriSP.trace("__IriSP.addListeners","ADD  Listener ");
+		__IriSP.player.addEventListener("onStateChange", "__IriSP.YouTubeStateMonitor");
+		setTimeout("__IriSP.YouTubePositionListener()",100);
+		__IriSP.player.addModelListener("VOLUME", "__IriSP.volumeListener");
+		//__IriSP.player.addModelListener('STATE', '__IriSP.stateMonitor');
+	} else {
+		__IriSP.setTimeout("__IriSP.YouTubePositionListener()",100);
+	}
+}
+__IriSP.YouTubePositionListener = function() { 
+	
+	__IriSP.currentPosition = __IriSP.player.getCurrentTime();
+	//__IriSP.trace("__IriSP.YouTubePositionListener",__IriSP.currentPosition);
+	//__IriSP.trace("__IriSP.currentPosition",__IriSP.currentPosition);
+	
+	__IriSP.MyLdt.checkTime(__IriSP.currentPosition);
+	__IriSP.jQuery("#slider-range-min").slider("value",__IriSP.currentPosition);
+	__IriSP.jQuery("#amount").val(__IriSP.currentPosition+" s");
+	// afficher annotation 
+	__IriSP.MyLdt.checkTime(__IriSP.currentPosition);
+	
+	
+	setTimeout("__IriSP.YouTubePositionListener()",10);
+}
+__IriSP.YouTubeStateMonitor = function (obj) { 
+	__IriSP.player.addModelListener('__IriSP.YouTubeStateMonitor ', newstate);
+	//alert(newstate+" "+obj.newstate);
+	 if(newstate == '2')
+    {
+		__IriSP.trace("__IriSP.stateMonitor","PAUSE");
+		__IriSP.MyApiPlayer.changePageUrlOffset(__IriSP.currentPosition);			
+		
+	}else if (newstate == '1'){
+		// une fois la video prete a lire  la déplacer au bon timecode 
+		if(__IriSP.startPosition!=null){
+			__IriSP.MyApiPlayer.update(__IriSP.startPosition);
+			__IriSP.startPosition = null;
+		}
+	} 
+	else if (newstate == '-1'){
+		// une fois la video prete a lire  la déplacer au bon timecode 
+		if(__IriSP.startPosition!=null){
+			__IriSP.MyApiPlayer.update(__IriSP.startPosition);
+			__IriSP.startPosition = null;
+		}
+	} else if (newstate == '3'){
+		__IriSP.trace("__IriSP.stateMonitor","BUFFERING : ");
+		//changePageUrlOffset(currentPosition);
+	}
+	
+}
+
+/* API JW PLAYER 	*/
 __IriSP.playerReady  = function (thePlayer) {
 
 	//__IriSP.trace("__IriSP.playerReady","PLAYER READY !!!!!!!!!!!!");
@@ -655,17 +894,20 @@
 		__IriSP.player.addControllerListener("VOLUME", "__IriSP.volumeListener");
 		__IriSP.player.addModelListener('STATE', '__IriSP.stateMonitor');
 	} else {
-		__IriSP.setTimeout("addListeners()",100);
+		__IriSP.setTimeout("__IriSP.addListeners()",100);
 	}
 
 	// et changer les boutons
 }
 __IriSP.stateMonitor = function (obj) { 
 
+
+	
 	 if(obj.newstate == 'PAUSED')
     {
 		__IriSP.trace("__IriSP.stateMonitor","PAUSE");
 		__IriSP.MyApiPlayer.changePageUrlOffset(__IriSP.currentPosition);			
+		__IriSP.jQuery(".ui-icon-play").css("background-position","0px -160px");
 		
 	} else if (obj.newstate == 'PLAYING'){
 		// une fois la video prete a lire  la déplacer au bon timecode 
@@ -673,6 +915,7 @@
 			__IriSP.MyApiPlayer.update(__IriSP.startPosition);
 			__IriSP.startPosition = null;
 		}
+		__IriSP.jQuery(".ui-icon-play").css("background-position","-16px -160px");
 	} else if (obj.newstate == 'BUFFERING'){
 		__IriSP.trace("__IriSP.stateMonitor","BUFFERING : ");
 		//changePageUrlOffset(currentPosition);
@@ -688,6 +931,8 @@
 	__IriSP.jQuery("#amount").val(obj.position+" s");
 	// afficher annotation 
 	__IriSP.MyLdt.checkTime(__IriSP.currentPosition);
+	
+	
 }
 __IriSP.volumeListener   = function (obj) { 
 	__IriSP.currentVolume = obj.percentage; 
@@ -729,6 +974,7 @@
 	//
 	this.annotations = new Array();
 	this.duration = duration;
+	this.annotationOldRead="";
 	__IriSP.LDTligne = this;
 	__IriSP.trace("__IriSP.Ligne","CREATE "+__IriSP.LDTligne);
 }	
@@ -773,9 +1019,10 @@
 __IriSP.Ligne.prototype.checkTime = function(time){
 	var annotationTempo = -1;
 	//__IriSP.trace("__IriSP.Ligne.prototype.checkTimeLigne",time);
+	//__IriSP.trace("__IriSP.Ligne.prototype.checkTimeLigne",this.annotations.length);
 	
 	for (var i=0; i < this.annotations.length; ++i){
-		var annotationTempo = this.annotations[i];	
+		annotationTempo = this.annotations[i];	
 		if (time>annotationTempo.begin/1000 && time<annotationTempo.end/1000){
 			
 				// different form the previous
@@ -790,29 +1037,37 @@
 					//__IriSP.trace("__IriSP.Ligne.prototype.checkTimeLigne",annotationTempo.title+" "+annotationTempo.description );
 					__IriSP.jQuery("#Ldt-SaTitle").text(annotationTempo.title);
 					__IriSP.jQuery("#Ldt-SaDescription").text(annotationTempo.description);
-					
-					__IriSP.jQuery("#Ldt-SaDescription").text(annotationTempo.description);
 					__IriSP.jQuery("#Ldt-SaKeywordText").html("Mots clefs : "+annotationTempo.htmlTags);
 					
 					//__IriSP.jQuery('#Ldt-ShowAnnotation').slideDown();
 					var startPourcent 	= annotationTempo.timeToPourcent((annotationTempo.begin*1+(annotationTempo.end*1-annotationTempo.begin*1)/2),annotationTempo.duration*1); 
 					__IriSP.jQuery("#Ldt-Show-Arrow").animate({left:startPourcent+'%'},1000);
+					__IriSP.jQuery("#"+annotationTempo.id).animate({alpha:'100%'},1000);
 					//alert(startPourcent);
 					var tempolinkurl  =  __IriSP.ignoreTimeFragment(window.location.href)+"#t="+(this.annotations[i].begin/1000);
 				}
 			break;
-		} 
+		}else{
+		annotationTempo=-1;
+		}		
 		
 	}
 	// si il y en a pas : retractation du volet 
 	if( annotationTempo == -1){
 		if(annotationTempo!=this.annotationOldRead){
 			__IriSP.trace("Check : ","pas d'annotation ici ");
+			__IriSP.jQuery("#Ldt-SaTitle").text("");
+			__IriSP.jQuery("#Ldt-SaDescription").text("");
+			__IriSP.jQuery("#Ldt-SaKeywordText").html("");
 			__IriSP.jQuery('#Ldt-ShowAnnotation').slideUp();
+			if(this.annotationOldRead){
+				__IriSP.jQuery("#"+this.annotationOldRead.id).animate({alpha:'70%'},1000);
+			}
+			//__IriSP.jQuery("#Ldt-Show-Arrow").animate({left:'0%'},1000);
 			this.annotationOldRead = annotationTempo;
 		}
 	}
-	
+	__IriSP.trace("__IriSP.Ligne.prototype.checkTimeLigne",annotationTempo);
 }
 
 
@@ -827,7 +1082,7 @@
 	var title 			= null;
 	var color 			= null;
 	var tags			= null;
-	__IriSP.trace("annotation ","r�ussi")
+	__IriSP.trace("annotation ","réussi")
 }	
 __IriSP.Annotation = function(id,begin,end,media,title,description,color,tags,duration){
 	this.id 			= id;
--- a/client/player/src/js/LdtPlayer.min.js	Wed Dec 01 16:29:15 2010 +0100
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,64 +0,0 @@
-/* 
- * 	
- *	Copyright 2010 Institut de recherche et d'innovation 
- *	contributor(s) : Samuel Huron 
- *	 
- *	contact@iri.centrepompidou.fr
- *	http://www.iri.centrepompidou.fr 
- *	 
- *	This software is a computer program whose purpose is to show and add annotations on a video .
- *	This software is governed by the CeCILL-C license under French law and
- *	abiding by the rules of distribution of free software. You can  use, 
- *	modify and/ or redistribute the software under the terms of the CeCILL-C
- *	license as circulated by CEA, CNRS and INRIA at the following URL
- *	"http://www.cecill.info". 
- *	
- *	The fact that you are presently reading this means that you have had
- *	knowledge of the CeCILL-C license and that you accept its terms.
-*/
-if(window.__IriSP===undefined)var __IriSP={};__IriSP.config={metadata:{format:"cinelab",src:"http://exp.iri.centrepompidou.fr/franceculture/franceculture/ldt/cljson/id/ef4dcc2e-8d3b-11df-8a24-00145ea4a2be",load:"jsonp"},gui:{width:650,height:0,mode:"radio",container:"LdtPlayer",debug:false,css:"../src/css/LdtPlayer.css"},player:{type:"jwplayer",src:"../res/swf/player.swf"},module:null};
-__IriSP.lib={jQuery:"http://ajax.googleapis.com/ajax/libs/jquery/1.4.2/jquery.min.js",jQueryUI:"http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.4/jquery-ui.min.js",jQueryToolTip:"http://cdn.jquerytools.org/1.2.4/all/jquery.tools.min.js",swfObject:"http://ajax.googleapis.com/ajax/libs/swfobject/2.2/swfobject.js",cssjQueryUI:"http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.4/themes/base/jquery-ui.css"};__IriSP.LdtShareTool="\n<a onclick=\"__IriSP.MyApiPlayer.share('delicious');\" title='partager avec delicious'><span class='share shareDelicious'>&nbsp;</span></a>\n<a onclick=\"__IriSP.MyApiPlayer.share('facebook');\" title='partager avec facebook'> <span class='share shareFacebook'>&nbsp;</span></a>\n<a onclick=\"__IriSP.MyApiPlayer.share('twitter');\" title='partager avec twitter'>  <span class='share shareTwitter'>&nbsp;</span></a>\n<a onclick=\"__IriSP.MyApiPlayer.share('myspace');\" title='partager avec Myspace'>  <span class='share shareMySpace'>&nbsp;</span></a>\n<a onclick=\"__IriSP.MyApiPlayer.share('jamespot');\" title='partager avec JamesPot'>  <span class='share shareJamesPot'>&nbsp;</span></a>";
-__IriSP.MyLdt=null;__IriSP.MyTags=null;__IriSP.MyApiPlayer=null;__IriSP.player=null;__IriSP.Durration=null;__IriSP.playerLdtWidth=null;__IriSP.playerLdtHeight=null;
-__IriSP.init=function(a){function b(){var f=document.createElement("script");f.setAttribute("type","text/javascript");f.setAttribute("src",__IriSP.lib.jQueryToolTip);f.onload=c;f.onreadystatechange=function(){if(this.readyState=="complete"||this.readyState=="loaded")c("jquery.tools.min.js loded")};var i=document.createElement("script");i.setAttribute("type","text/javascript");i.setAttribute("src",__IriSP.lib.swfObject);i.onload=c;i.onreadystatechange=function(){if(this.readyState=="complete"||this.readyState==
-"loaded")c("swfobject.js loded")};var j=document.createElement("script");j.setAttribute("type","text/javascript");j.setAttribute("src",__IriSP.lib.jQueryUI);j.onload=c;j.onreadystatechange=function(){if(this.readyState=="complete"||this.readyState=="loaded")c("jquery-ui.min.js loded")};(document.getElementsByTagName("head")[0]||document.documentElement).appendChild(f);(document.getElementsByTagName("head")[0]||document.documentElement).appendChild(j);(document.getElementsByTagName("head")[0]||document.documentElement).appendChild(i)}
-function c(){g+=1;g===3&&d()}function d(){__IriSP.jQuery=window.jQuery.noConflict(true);__IriSP.jQuery(document).ready(function(f){var i=__IriSP.jQuery("<link>",{rel:"stylesheet",type:"text/css",href:__IriSP.lib.cssjQueryUI,"class":"dynamic_css"}),j=__IriSP.jQuery("<link>",{rel:"stylesheet",type:"text/css",href:__IriSP.config.gui.css,"class":"dynamic_css"});i.appendTo("head");j.appendTo("head");f.browser.msie&&f(".dynamic_css").clone().appendTo("head");__IriSP.createMyHtml();__IriSP.jQuery.ajax({dataType:"jsonp",
-url:h,success:function(e){__IriSP.trace("ajax","success");if(e==="")alert("ERREUR DE CHARGEMENT JSON");else{new __IriSP.Media(e.medias[0].id,e.medias[0].href,e.medias[0].meta["dc:duration"],e.medias[0]["dc:title"],e.medias[0]["dc:description"]);__IriSP.trace("__IriSP.MyApiPlayer",__IriSP.config.gui.width+"   "+__IriSP.config.gui.height+" "+e.medias[0].href+" "+e.medias[0].meta["dc:duration"]+" "+e.medias[0].meta.item.value);__IriSP.MyApiPlayer=new __IriSP.APIplayer(__IriSP.config.gui.width,__IriSP.config.gui.height,
-e.medias[0].href,e.medias[0].meta["dc:duration"],e.medias[0].meta.item.value);__IriSP.trace("__IriSP.init.main","__IriSP.Ligne");__IriSP.MyLdt=new __IriSP.Ligne(e["annotation-types"][0].id,e["annotation-types"][0]["dc:title"],e["annotation-types"][0]["dc:description"],e.medias[0].meta["dc:duration"]);__IriSP.trace("__IriSP.init.main","__IriSP.Tags");__IriSP.MyTags=new __IriSP.Tags(e.tags);__IriSP.jQuery.each(e.annotations,function(l,k){k.meta["id-ref"]==__IriSP.MyLdt.id&&__IriSP.MyLdt.addAnnotation(k.id,
-k.begin,k.end,k.media,k.content.title,k.content.description,k.content.color,k.tags)});__IriSP.jQuery.each(e.lists,function(){__IriSP.trace("lists","")});__IriSP.jQuery.each(e.views,function(){__IriSP.trace("views","")})}},error:function(e){alert("ERROR : "+e)}})})}__IriSP.config=a;var h=__IriSP.config.metadata.src;__IriSP.jQuery=null;if(window.jQuery===undefined||window.jQuery.fn.jquery!=="1.4.2"){a=document.createElement("script");a.setAttribute("type","text/javascript");a.setAttribute("src",__IriSP.lib.jQuery);
-a.onload=b;a.onreadystatechange=function(){if(this.readyState=="complete"||this.readyState=="loaded")b()};(document.getElementsByTagName("head")[0]||document.documentElement).appendChild(a)}else{__IriSP.jQuery=window.jQuery;b()}var g=0};
-__IriSP.createMyHtml=function(){var a=__IriSP.config.gui.width;__IriSP.jQuery("<div id='Ldt-Root'>\n\t<div id='Ldt-PlaceHolder'>\n\t\t<a href='http://www.adobe.com/go/getflashplayer'>Get flash</a> to see this player\t\n\t</div>\n\t<div id='Ldt-controler' class='demo'>\n\t\t<div class='Ldt-Control1' >\n\t\t\t<button id='ldt-CtrlPlay' onclick='__IriSP.MyApiPlayer.play()'>Lecture / Pause </button>\n\t\t\t<button id='ldt-CtrlNext' onclick='__IriSP.MyLdt.nextAnnotation()'>Suivant</button>\n\t\t</div>\n\t\t<div id='Ldt-Annotations' class='ui-slider'>\n\t\t\t<div id='slider-range-min'></div>\n\t</div>\n\t\t<div class='Ldt-Control2'>\n\t\t\t<button id='ldt-CtrlLink'> Partager </button>\n\t\t\t<button id='ldt-CtrlSound' onclick='__IriSP.MyApiPlayer.mute()'>Sound</button>\n\t\t</div>\n  <div class='cleaner'>&nbsp;</div> \n  <div id='Ldt-Show-Arrow-container'>\n  \t<div id='Ldt-Show-Arrow'> </div>\n  </div>\n</div>\n<div>\n <div id='ldt-Show'> </div>\n\t<div id='Ldt-ShowAnnotation-audio' class='demo' >\n\t\t<div id='Ldt-SaTitle'></div>\n\t\t<div id='Ldt-SaDescription'></div>\n \t\t<div class='cleaner'><!--&nbsp;--\></div>\n </div>\n <div id='Ldt-SaKeyword'>\n <div id='Ldt-SaKeywordText'>  </div>\n <div class='cleaner'></div>\n <div id='Ldt-SaShareTools'>\n \n "+__IriSP.LdtShareTool+
-"\n \n  </div>\n <div class='cleaner'></div></div>  </div><div id='Ldt-output'></div>").appendTo("#"+__IriSP.config.gui.container);__IriSP.trace("__IriSP.createHtml","end");__IriSP.jQuery("#Ldt-Annotations").width(a-150);__IriSP.jQuery("#Ldt-Show-Arrow-container").width(a-150);__IriSP.jQuery("#Ldt-ShowAnnotation-audio").width(a-10);__IriSP.jQuery("#Ldt-ShowAnnotation-video").width(a-10);__IriSP.jQuery("#Ldt-SaKeyword").width(a-10);__IriSP.jQuery("#Ldt-controler").width(a-10);__IriSP.jQuery("#Ldt-Control").attr("z-index",
-"100");__IriSP.jQuery("#Ldt-controler").hide();__IriSP.jQuery("<div id='Ldt-load-container'><div id='Ldt-loader'>&nbsp;</div> Chargement... </div>").appendTo("#Ldt-ShowAnnotation-audio");__IriSP.config.gui.mode=="radio"&&__IriSP.jQuery("#Ldt-load-container").attr("width",__IriSP.config.gui.width);__IriSP.config.gui.debug===true?__IriSP.jQuery("#Ldt-output").show():__IriSP.jQuery("#Ldt-output").hide()};
-__IriSP.Media=function(a,b,c,d,h){this.id=a;this.url=b;this.title=d;this.description=h;this.duration=c;this.lignes=[];__IriSP.trace("__IriSP.Media","Media ID : "+a);__IriSP.trace("__IriSP.Media","Media URL : "+b);__IriSP.trace("__IriSP.Media","Media title : "+d)};__IriSP.Media.prototype.createPlayerMedia=function(a,b,c,d){__IriSP.MyApiPlayer=new __IriSP.APIplayer(a,b,this.url,this.duration,c,d)};__IriSP.Media.prototype.getMediaDuration=function(){return this.duration};
-__IriSP.Media.prototype.getMediaTitle=function(){return this.title};
-__IriSP.createInterface=function(a,b,c){__IriSP.jQuery("#Ldt-controler").show();__IriSP.trace("__IriSP.createInterface",a+","+b+","+c+",");__IriSP.jQuery("#Ldt-ShowAnnotation").click(function(){});__IriSP.jQuery("#Ldt-PlaceHolder").attr("top");__IriSP.jQuery("#Ldt-PlaceHolder").attr("left");__IriSP.jQuery("#slider-range-min").slider({value:0,min:1,max:c/1E3,step:0.1,slide:function(d,h){__IriSP.MyApiPlayer.seek(h.value)}});__IriSP.trace("__IriSP.createInterface","ICI");__IriSP.jQuery("#amount").val(__IriSP.jQuery("#slider-range-min").slider("value")+
-" s");__IriSP.jQuery(".Ldt-Control1 button:first").button({icons:{primary:"ui-icon-play"},text:false}).next().button({icons:{primary:"ui-icon-seek-next"},text:false});__IriSP.jQuery(".Ldt-Control2 button:first").button({icons:{primary:"ui-icon-transferthick-e-w"},text:false}).next().button({icons:{primary:"ui-icon-volume-on"},text:false});__IriSP.trace("__IriSP.createInterface","ICI2");__IriSP.jQuery("#ldt-CtrlPlay").attr("style","background-color:#CD21C24;");__IriSP.jQuery("#Ldt-load-container").hide();
-__IriSP.config.gui.mode=="radio"&__IriSP.jQuery.browser.msie!=true&&__IriSP.jQuery("#Ldtplayer1").attr("height","0");__IriSP.trace("__IriSP.createInterface","3");__IriSP.trace("__IriSP.createInterface","END")};
-__IriSP.APIplayer=function(a,b,c,d,h,g){this.hashchangeUpdate=this.player=null;this.width=a;this.height=b;this.url=c;this.duration=d;this.streamerPath=h;this.MySwfPath=g;__IriSP.MyApiPlayer=this;__IriSP.createPlayer(a,b,this.url,this.duration,this.streamerPath,this.MySwfPath);__IriSP.trace("__IriSP.APIplayer","__IriSP.createPlayer")};
-__IriSP.APIplayer.prototype.ready=function(){__IriSP.createInterface(this.width,this.height,this.duration);__IriSP.trace("__IriSP.APIplayer.prototype.APIpReady","END  __IriSP.createInterface");if(window.addEventListener)window.addEventListener("hashchange",function(){var a=__IriSP.retrieveTimeFragment(window.location.href);__IriSP.trace("__IriSP.APIplayer.prototype.ready",a);if(__IriSP.MyApiPlayer.hashchangeUpdate==null)__IriSP.MyApiPlayer.seek(a);else __IriSP.MyApiPlayer.hashchangeUpdate=null},false);
-else window.attachEvent&&window.attachEvent("onhashchange",function(){__IriSP.trace("hashchange",a);var a=__IriSP.retrieveTimeFragment(window.location.href);if(__IriSP.MyApiPlayer.hashchangeUpdate==null)__IriSP.MyApiPlayer.seek(a);else __IriSP.MyApiPlayer.hashchangeUpdate=null},false)};__IriSP.APIplayer.prototype.pause=function(){this.hashchangeUpdate=true;__IriSP.player.sendEvent("PAUSE")};__IriSP.APIplayer.prototype.play=function(){this.hashchangeUpdate=true;__IriSP.player.sendEvent("PLAY")};
-__IriSP.APIplayer.prototype.mute=function(){__IriSP.player.sendEvent("MUTE")};
-__IriSP.APIplayer.prototype.share=function(a){var b=window.location.href,c;if(a=="facebook")c="http://www.facebook.com/share.php?u=";else if(a=="twitter")c="http://twitter.com/home?status=Je regarde :";else if(a=="myspace")c="http://www.myspace.com/Modules/PostTo/Pages/?u=";else if(a=="delicious")c="http://delicious.com/save?url=";else if(a=="JameSpot")c="http://www.jamespot.com/?action=spotit&u=";window.location.href=c+encodeURIComponent(b)};
-__IriSP.APIplayer.prototype.seek=function(a){__IriSP.player.sendEvent("SEEK",a);this.changePageUrlOffset(a)};__IriSP.APIplayer.prototype.update=function(a){this.hashchangeUpdate=true;__IriSP.player.sendEvent("SEEK",a)};__IriSP.APIplayer.prototype.changePageUrlOffset=function(a){__IriSP.trace("__IriSP.APIplayer.prototype.changePageUrlOffset","CHANGE URL "+a);window.location.hash="#t="+a;window.location.href=window.location.href};__IriSP.jumpToTimeoffset=function(a){__IriSP.MyApiPlayer.changePageUrlOffset(a.time.value)};
-__IriSP.retrieveTimeFragment=function(a){var b=0,c=0;if(a.split("#")[1]!=null){b=a.split("#")[1];if(b.substring(2)!=null)c=b.substring(2)}return c};__IriSP.ignoreTimeFragment=function(a){if(a.split("#")[1]!=null)var b=a.split("#")[0];return b};__IriSP.currentPosition=0;__IriSP.currentVolume=50;__IriSP.player=null;__IriSP.startPosition=null;
-__IriSP.createPlayer=function(a,b,c,d,h){__IriSP.trace("__IriSP.createPlayer","start");__IriSP.myUrlFragment=c.split(h);c={streamer:h,file:__IriSP.myUrlFragment[1],live:"true",autostart:"true",controlbar:"none",playerready:"__IriSP.playerReady"};__IriSP.trace("__IriSP.createPlayer","SWFOBJECT src:"+__IriSP.config.player.src+" "+a+" "+b);swfobject.embedSWF(__IriSP.config.player.src,"Ldt-PlaceHolder",a,b,"9.0.115",false,c,{allowfullscreen:"true",allowscriptaccess:"always",wmode:"transparent"},{id:"Ldtplayer1",
-name:"Ldtplayer1"})};__IriSP.playerReady=function(a){__IriSP.player=window.document[a.id];__IriSP.MyApiPlayer.ready(__IriSP.player);a=__IriSP.retrieveTimeFragment(document.location.href);__IriSP.startPosition=a;__IriSP.addListeners()};
-__IriSP.addListeners=function(){if(__IriSP.player){__IriSP.trace("__IriSP.addListeners","ADD  Listener ");__IriSP.player.addModelListener("TIME","__IriSP.positionListener");__IriSP.player.addControllerListener("VOLUME","__IriSP.volumeListener");__IriSP.player.addModelListener("STATE","__IriSP.stateMonitor")}else __IriSP.setTimeout("addListeners()",100)};
-__IriSP.stateMonitor=function(a){if(a.newstate=="PAUSED"){__IriSP.trace("__IriSP.stateMonitor","PAUSE");__IriSP.MyApiPlayer.changePageUrlOffset(__IriSP.currentPosition)}else if(a.newstate=="PLAYING"){if(__IriSP.startPosition!=null){__IriSP.MyApiPlayer.update(__IriSP.startPosition);__IriSP.startPosition=null}}else a.newstate=="BUFFERING"&&__IriSP.trace("__IriSP.stateMonitor","BUFFERING : ")};
-__IriSP.positionListener=function(a){__IriSP.currentPosition=a.position;var b=document.getElementById("posit");if(b)b.innerHTML="position: "+__IriSP.currentPosition;__IriSP.jQuery("#slider-range-min").slider("value",a.position);__IriSP.jQuery("#amount").val(a.position+" s");__IriSP.MyLdt.checkTime(__IriSP.currentPosition)};__IriSP.volumeListener=function(a){__IriSP.currentVolume=a.percentage;if(a=document.getElementById("vol"))a.innerHTML="volume: "+__IriSP.currentVolume};
-__IriSP.stripHtml=function(a){return a.replace(/\\&/g,"&amp;").replace(/\\</g,"&lt;").replace(/\\>/g,"&gt;").replace(/\\t/g,"&nbsp;&nbsp;&nbsp;").replace(/\\n/g,"<br />").replace(/'/g,"&#39;").replace(/"/g,"&quot;")};__IriSP.DEC_HEXA_COLOR=function(a){for(var b="",c;a>15;){c=a-Math.floor(a/16)*16;b="0123456789ABCDEF".charAt(c)+b;a=Math.floor(a/16)}b="0123456789ABCDEF".charAt(a)+b;if(b=="FFCC00")b="";return b};__IriSP.LDTligne=null;
-__IriSP.Ligne=function(a,b,c,d){this.id=a;this.title=b;this.description=c;this.annotations=[];this.duration=d;__IriSP.LDTligne=this;__IriSP.trace("__IriSP.Ligne","CREATE "+__IriSP.LDTligne)};__IriSP.Ligne.prototype.addAnnotation=function(a,b,c,d,h,g,f,i){this.annotations.push(new __IriSP.Annotation(a,b,c,d,h,g,f,i,this.duration))};__IriSP.Ligne.prototype.onClickLigneAnnotation=function(){};__IriSP.Ligne.prototype.searchLigneAnnotation=function(){};__IriSP.Ligne.prototype.listAnnotations=function(){};
-__IriSP.Ligne.prototype.nextAnnotation=function(){var a=this.numAnnotation(this.annotationOldRead)+1,b=this.annotations[a];if(a<this.annotations.length-1){__IriSP.player.sendEvent("SEEK",b.begin/1E3);__IriSP.trace("LIGNE  ","| next = "+a+" - "+this.annotations.length+" | seek :"+b.begin/1E3)}else __IriSP.player.sendEvent("SEEK",this.annotations[0].begin/1E3)};__IriSP.Ligne.prototype.numAnnotation=function(a){for(var b=0;b<this.annotations.length;++b)if(a==this.annotations[b])return b};
-__IriSP.Ligne.prototype.checkTime=function(a){for(var b=-1,c=0;c<this.annotations.length;++c){b=this.annotations[c];if(a>b.begin/1E3&&a<b.end/1E3){if(b!=this.annotationOldRead){this.annotationOldRead=b;__IriSP.jQuery("#Ldt-SaTitle").text(b.title);__IriSP.jQuery("#Ldt-SaDescription").text(b.description);__IriSP.jQuery("#Ldt-SaDescription").text(b.description);__IriSP.jQuery("#Ldt-SaKeywordText").html("Mots clefs : "+b.htmlTags);a=b.timeToPourcent(b.begin*1+(b.end*1-b.begin*1)/2,b.duration*1);__IriSP.jQuery("#Ldt-Show-Arrow").animate({left:a+
-"%"},1E3);__IriSP.ignoreTimeFragment(window.location.href)}break}}if(b==-1)if(b!=this.annotationOldRead){__IriSP.trace("Check : ","pas d'annotation ici ");__IriSP.jQuery("#Ldt-ShowAnnotation").slideUp();this.annotationOldRead=b}};__IriSP.Annotation=function(){__IriSP.trace("annotation ","r\ufffdussi")};
-__IriSP.Annotation=function(a,b,c,d,h,g,f,i,j){this.id=a;this.begin=b;this.end=c;this.media=d;this.description=g;this.title=h;this.color=f;this.tags=i;this.htmlTags="";this.duration=j;this.draw();this.drawTags();__IriSP.trace("Annotation created : ",a)};
-__IriSP.Annotation.prototype.draw=function(){var a=this.timeToPourcent(this.begin,this.duration),b=this.timeToPourcent(this.end,this.duration)-a,c=this.title.substr(0,55);__IriSP.jQueryAnnotationTemplate="<div title='"+__IriSP.stripHtml(c)+"' id='"+this.id+"'  class='ui-slider-range ui-slider-range-min ui-widget-header iri-chapter' width='100%' style=\"left:"+a+"%; width:"+b+"%; padding-top:15px; border-left:solid 1px #aaaaaa; border-right:solid 1px #aaaaaa; background:#"+__IriSP.DEC_HEXA_COLOR(this.color)+
-';" onClick="__IriSP.MyApiPlayer.seek(\''+Math.round(this.begin/1E3)+"');__IriSP.jQuery('#Ldt-ShowAnnotation').slideDown();\"    ></div> ";__IriSP.jQuerytoolTipTemplate="<div class='Ldt-tooltip'><div class='title'>"+__IriSP.stripHtml(this.title)+"</div><div class='time'>"+this.begin+" : "+this.end+"</div><div class='description'>"+__IriSP.stripHtml(this.description)+"</div></div>";__IriSP.jQuery("<div>"+__IriSP.jQueryAnnotationTemplate+"</div>").appendTo("#Ldt-Annotations");__IriSP.jQuery("#"+this.id).tooltip({effect:"slide"});
-__IriSP.jQuery("#"+this.id).fadeTo(0,0.3);__IriSP.jQuery("#"+this.id).mouseover(function(){__IriSP.jQuery("#"+this.id).animate({opacity:0.6},5)}).mouseout(function(){__IriSP.jQuery("#"+this.id).animate({opacity:0.3},5)});__IriSP.trace("__IriSP.Annotation.prototype.draw","ADD ANOTATION : "+this.begin+" "+this.end+" "+__IriSP.stripHtml(this.title)+" | "+a+" | "+b+" | duration = "+this.duration)};
-__IriSP.Annotation.prototype.drawTags=function(){if(this.tags!=undefined)for(var a=0;a<this.tags.length;++a)this.htmlTags+="<span> "+__IriSP.MyTags.getTitle(this.tags[a]["id-ref"])+" </span> , "};__IriSP.Annotation.prototype.tootTipAnnotation=function(){return this.color+" "+this.type+" apple"};__IriSP.Annotation.prototype.onRollOverAnnotation=function(){this.tootTip()};__IriSP.Annotation.prototype.timeToPourcent=function(a,b){return parseInt(Math.round(a/b*100))};
-__IriSP.Tags=function(a){this.myTags=a;this.htmlTags=null;this.weigthMax=0};__IriSP.Tags.prototype.addAnnotation=function(a){for(var b=0;b<this.myTags.length;++b){this.myTags[b].mySegments=[];if(a.tags!=null)for(var c=0;c<a.tags.length;++c)if(this.myTags[b].id==a.tags[c]["id-ref"]){this.myTags[b].mySegments.push([a.begin,a.end,a.id]);var d=this.myTags[b].mySegments.length;if(this.weigthMax<d)this.weigthMax=d}}};
-__IriSP.Tags.prototype.getTitle=function(a){for(var b=0;b<this.myTags.length;++b)if(this.myTags[b].id==a)return this.myTags[b].meta["dc:title"]};
-__IriSP.Tags.prototype.draw=function(){__IriSP.trace("__IriSP.Tags.prototype.draw"," !!! WELL START ");for(var a=0;a<this.myTags.length;++a){__IriSP.trace("__IriSP.Tags.prototype.draw"," ADD Tags : "+this.myTags[a].id);if(this.myTags[a].id!=null)this.htmlTags+="<span onclick=\"MyTags.show( '"+this.myTags[a].id+'\');" style="font-size:'+(this.myTags[a].mySegments.length/this.weigthMax*10+8)+'px;" alt="'+this.myTags[a].mySegments.length+'"> '+this.myTags[a].meta["dc:title"]+" </span> , "}__IriSP.jQuery("#Ldt-Tags").html(this.htmlTags);
-__IriSP.trace("__IriSP.Tags.prototype.draw"," !!!!  END WMAX= "+this.weigthMax)};
-__IriSP.Tags.prototype.show=function(a){for(var b=1.0E20,c=1.0E20,d=0,h=0,g=0;g<this.myTags.length;++g)if(this.myTags[g].id==a){__IriSP.trace("######### TAG DRAWing : "," END");for(var f=0;f<this.myTags[g].mySegments.length;++f){if(void 0>this.myTags[g].mySegments[f][0]){b=this.myTags[g].mySegments[f][0];c=this.myTags[g].mySegments[f][1]}if(void 0>this.myTags[g].mySegments[f][0]){d=this.myTags[g].mySegments[f][0];h=this.myTags[g].mySegments[f][1]}}}a=__IriSP.timeToPourcent(b*1+(c-b)/2,__IriSP.MyLdt.duration);
-d=__IriSP.timeToPourcent(d*1+(h-d)/2,__IriSP.MyLdt.duration)-a;__IriSP.jQuery("#Ldt-Show-Tags").css("left",a+"%");__IriSP.jQuery("#Ldt-Show-Tags").css("width",d+"%")};__IriSP.traceNum=0;__IriSP.trace=function(a,b){if(__IriSP.config.gui.debug===true){__IriSP.traceNum+=1;__IriSP.jQuery("<div>"+__IriSP.traceNum+" - "+a+" : "+b+"</div>").appendTo("#Ldt-output")}};
\ No newline at end of file