32 '{{#show_arrow}}<div class="Ldt-Annotation-Arrow"></div>{{/show_arrow}}' |
32 '{{#show_arrow}}<div class="Ldt-Annotation-Arrow"></div>{{/show_arrow}}' |
33 + '<div class="Ldt-Annotation-Widget {{^show_arrow}}Ldt-Annotation-ShowTop{{/show_arrow}}">' |
33 + '<div class="Ldt-Annotation-Widget {{^show_arrow}}Ldt-Annotation-ShowTop{{/show_arrow}}">' |
34 + '<div class="Ldt-Annotation-Inner Ldt-Annotation-Empty{{#start_minimized}} Ldt-Annotation-Minimized{{/start_minimized}}">' |
34 + '<div class="Ldt-Annotation-Inner Ldt-Annotation-Empty{{#start_minimized}} Ldt-Annotation-Minimized{{/start_minimized}}">' |
35 + '<div class="Ldt-Annotation-HiddenWhenEmpty Ldt-Annotation-MaxMinButton"></div>' |
35 + '<div class="Ldt-Annotation-HiddenWhenEmpty Ldt-Annotation-MaxMinButton"></div>' |
36 + '{{#show_social}}<div class="Ldt-Annotation-Social Ldt-Annotation-HiddenWhenMinimized Ldt-Annotation-HiddenWhenEmpty"></div>{{/show_social}}' |
36 + '{{#show_social}}<div class="Ldt-Annotation-Social Ldt-Annotation-HiddenWhenMinimized Ldt-Annotation-HiddenWhenEmpty"></div>{{/show_social}}' |
37 + '<h3 class="Ldt-Annotation-HiddenWhenEmpty" draggable="true">{{#show_annotation_type}}<span class="Ldt-Annotation-Type"></span> » {{/show_annotation_type}}<span class="Ldt-Annotation-Title"></span> <span class="Ldt-Annotation-Time Ldt-Annotation-HiddenWhenMinimized">' |
37 + '<h3 class="Ldt-Annotation-HiddenWhenEmpty">{{#show_annotation_type}}<span class="Ldt-Annotation-Type"></span> » {{/show_annotation_type}}<span class="Ldt-Annotation-Title"></span> <span class="Ldt-Annotation-Time Ldt-Annotation-HiddenWhenMinimized">' |
38 + '(<span class="Ldt-Annotation-Begin"></span> - <span class="Ldt-Annotation-End"></span>)</span></h3>' |
38 + '(<span class="Ldt-Annotation-Begin"></span> - <span class="Ldt-Annotation-End"></span>)</span></h3>' |
39 + '<h3 class="Ldt-Annotation-MashupOrigin Ldt-Annotation-HiddenWhenEmpty">{{l10n.excerpt_from}} <span class="Ldt-Annotation-MashupMedia"></span> <span class="Ldt-Annotation-Time Ldt-Annotation-HiddenWhenMinimized">' |
39 + '<h3 class="Ldt-Annotation-MashupOrigin Ldt-Annotation-HiddenWhenEmpty">{{l10n.excerpt_from}} <span class="Ldt-Annotation-MashupMedia"></span> <span class="Ldt-Annotation-Time Ldt-Annotation-HiddenWhenMinimized">' |
40 + '(<span class="Ldt-Annotation-MashupBegin"></span> - <span class="Ldt-Annotation-MashupEnd"></span>)</span></h3>' |
40 + '(<span class="Ldt-Annotation-MashupBegin"></span> - <span class="Ldt-Annotation-MashupEnd"></span>)</span></h3>' |
41 + '<div class="Ldt-Annotation-Cleared Ldt-Annotation-HiddenWhenMinimized Ldt-Annotation-HiddenWhenEmpty Ldt-Annotation-Description-Block"><div class="Ldt-Annotation-Label">{{l10n.description_}}</div>' |
41 + '<div class="Ldt-Annotation-Cleared Ldt-Annotation-HiddenWhenMinimized Ldt-Annotation-HiddenWhenEmpty Ldt-Annotation-Description-Block"><div class="Ldt-Annotation-Label">{{l10n.description_}}</div>' |
42 + '<p class="Ldt-Annotation-Labelled Ldt-Annotation-Description"></p></div>' |
42 + '<p class="Ldt-Annotation-Labelled Ldt-Annotation-Description"></p></div>' |
165 }); |
165 }); |
166 }); |
166 }); |
167 this.source.getAnnotations().on("found", highlightTitleAndDescription); |
167 this.source.getAnnotations().on("found", highlightTitleAndDescription); |
168 this.source.getAnnotations().on("not-found", highlightTitleAndDescription); |
168 this.source.getAnnotations().on("not-found", highlightTitleAndDescription); |
169 this.source.getAnnotations().on("search-cleared", highlightTitleAndDescription); |
169 this.source.getAnnotations().on("search-cleared", highlightTitleAndDescription); |
170 this.$.find("[draggable]").on("dragstart", function(e) { |
170 IriSP.attachDndData(this.$.find("h3"), function() { |
171 var url = (typeof currentAnnotation.url !== "undefined" |
171 return { |
172 ? currentAnnotation.url |
172 title: currentAnnotation.title, |
173 : (document.location.href.replace(/#.*$/,'') + '#id=' + currentAnnotation.id)); |
173 description: currentAnnotation.description, |
174 e.originalEvent.dataTransfer.setData("text/x-iri-title",currentAnnotation.title); |
174 image: currentAnnotation.thumbnail, |
175 e.originalEvent.dataTransfer.setData("text/x-iri-description",currentAnnotation.description); |
175 uri: (typeof currentAnnotation.url !== "undefined" |
176 e.originalEvent.dataTransfer.setData("text/x-iri-uri",url); |
176 ? currentAnnotation.url |
177 if (typeof currentAnnotation.thumbnail !== "undefined" && currentAnnotation.thumbnail) { |
177 : (document.location.href.replace(/#.*$/,'') + '#id=' + currentAnnotation.id)) |
178 e.originalEvent.dataTransfer.setData("text/x-iri-image",currentAnnotation.thumbnail); |
178 } |
179 } |
|
180 }); |
179 }); |
181 } |
180 } |
182 |
181 |
183 IriSP.Widgets.Annotation.prototype.sendBounds = function() { |
182 IriSP.Widgets.Annotation.prototype.sendBounds = function() { |
184 this.player.trigger("Annotation.boundsChanged",this.bounds); |
183 this.player.trigger("Annotation.boundsChanged",this.bounds); |