diff -r 1648489454d7 -r 843f96e4eebd web/res/metadataplayer/Annotation.js --- a/web/res/metadataplayer/Annotation.js Thu Jul 11 15:30:43 2013 +0200 +++ b/web/res/metadataplayer/Annotation.js Tue Jul 23 13:14:21 2013 +0200 @@ -13,9 +13,9 @@ fr: { watching: "Je regarde ", on_site: " sur ", - tags_: "Mots-clés :", - description_: "Description :", - excerpt_from: "Extrait de :", + tags_: "Mots-clés\u00a0:", + description_: "Description\u00a0:", + excerpt_from: "Extrait de\u00a0:", untitled: "Segment sans titre" }, en: { @@ -34,7 +34,7 @@ + '
' + '
' + '{{#show_social}}
{{/show_social}}' - + '

{{#show_annotation_type}} » {{/show_annotation_type}} ' + + '

{{#show_annotation_type}} » {{/show_annotation_type}} ' + '( - )

' + '

{{l10n.excerpt_from}} ' + '( - )

' @@ -48,6 +48,7 @@ annotation_type : "chap", start_minimized: false, show_arrow : true, + arrow_position: .5, site_name : "Lignes de Temps", search_on_tag_click: true, show_social: true, @@ -140,18 +141,27 @@ _this.$.find(".Ldt-Annotation-Inner").removeClass("Ldt-Annotation-Empty"); _this.bounds = [ _annotation.begin, _annotation.end ]; if (_this.arrow) { - _this.arrow.moveToTime((_annotation.begin + _annotation.end)/2); + _this.arrow.moveToTime((1 - _this.arrow_position) * _annotation.begin + _this.arrow_position * _annotation.end); } _this.sendBounds(); } this.renderTemplate(); + this.$.find(".Ldt-Annotation-Title").click(function() { + if (currentAnnotation) { + _this.media.setCurrentTime(currentAnnotation.begin); + } + return false; + }); + if (this.show_social) { this.insertSubwidget(this.$.find(".Ldt-Annotation-Social"), { type: "Social" }, "socialWidget"); } - this.insertSubwidget(this.$.find(".Ldt-Annotation-Arrow"), { type: "Arrow", width: this.width }, "arrow"); + if (this.show_arrow) { + this.insertSubwidget(this.$.find(".Ldt-Annotation-Arrow"), { type: "Arrow", width: this.width }, "arrow"); + } this.onMediaEvent("timeupdate",timeupdate); this.onMdpEvent("Annotation.hide","hide"); this.onMdpEvent("Annotation.show","show");