Index: trunk/phase3/js2/mwEmbed/libAddMedia/searchLibs/archiveOrgSearch.js |
— | — | @@ -87,7 +87,7 @@ |
88 | 88 | do_api_req( { |
89 | 89 | 'data':{'avinfo':1}, |
90 | 90 | 'url':_this.dnUrl + rObj.resourceKey + '/format=Ogg+video' |
91 | | - },function(data){ |
| 91 | + },function(data){ |
92 | 92 | if(data['length']) |
93 | 93 | rObj.duration = data['length']; |
94 | 94 | if(data['width']) |
— | — | @@ -103,7 +103,11 @@ |
104 | 104 | if(!options) |
105 | 105 | options ={}; |
106 | 106 | var id_attr = (options['id'])?' id = "' + options['id'] +'" ': ''; |
107 | | - var src = rObj.src + '?t=0:0:0/'+ seconds2npt( rObj.duration ); |
| 107 | + if( rObj.duration ){ |
| 108 | + var src = rObj.src + '?t=0:0:0/'+ seconds2npt( rObj.duration ); |
| 109 | + }else{ |
| 110 | + var src = rObj.src; |
| 111 | + } |
108 | 112 | if(rObj.mime == 'application/ogg' || rObj.mime == 'audio/ogg' || rObj.mime=='video/ogg'){ |
109 | 113 | return '<video ' + id_attr + ' src="' + src + '" poster="' + rObj.poster + '" type="video/ogg"></video>'; |
110 | 114 | } |
Index: trunk/phase3/js2/mwEmbed/libClipEdit/mvClipEdit.js |
— | — | @@ -1,7 +1,7 @@ |
2 | 2 | /* |
3 | | - hanndles clip edit controls |
| 3 | + handles clip edit controls |
4 | 4 | 'inoutpoints':0, //should let you set the in and out points of clip |
5 | | - 'panzoom':0, //should allow setting keyframes and tweenning modes |
| 5 | + 'panzoom':0, //should allow setting keyframes and tweening modes |
6 | 6 | 'overlays':0, //should allow setting "locked to clip" overlay tracks |
7 | 7 | 'audio':0 //should allow controlling the audio volume (with keyframes) |
8 | 8 | */ |
— | — | @@ -135,14 +135,16 @@ |
136 | 136 | var start_ntp = (_this.rObj.embed.start_ntp) ? _this.rObj.embed.start_ntp : seconds2npt( 0 ); |
137 | 137 | if(!start_ntp) |
138 | 138 | seconds2npt( 0 ); |
139 | | - |
140 | | - $j(target).html( |
141 | | - _this.getSetInOutHtml({ |
142 | | - 'start_ntp' : start_ntp, |
143 | | - 'end_ntp' : end_ntp |
144 | | - }) |
145 | | - ); |
146 | | - _this.setInOutBindings(); |
| 139 | + //make sure we have an end time |
| 140 | + if( end_ntp ){ |
| 141 | + $j(target).html( |
| 142 | + _this.getSetInOutHtml({ |
| 143 | + 'start_ntp' : start_ntp, |
| 144 | + 'end_ntp' : end_ntp |
| 145 | + }) |
| 146 | + ); |
| 147 | + _this.setInOutBindings(); |
| 148 | + } |
147 | 149 | } |
148 | 150 | }, |
149 | 151 | 'fileopts':{ |
— | — | @@ -378,13 +380,15 @@ |
379 | 381 | eb.preview_mode = true; |
380 | 382 | $j('#'+this.control_ct).html('<h3>' + gM('mwe-edit-video-tools') + '</h3>'); |
381 | 383 | if( eb.supportsURLTimeEncoding() ){ |
382 | | - $j('#'+this.control_ct).append( |
383 | | - _this.getSetInOutHtml({ |
384 | | - 'start_ntp' : eb.start_ntp, |
385 | | - 'end_ntp' : eb.end_ntp |
386 | | - }) |
387 | | - ); |
388 | | - _this.setInOutBindings(); |
| 384 | + if(eb.end_ntp){ |
| 385 | + $j('#'+this.control_ct).append( |
| 386 | + _this.getSetInOutHtml({ |
| 387 | + 'start_ntp' : eb.start_ntp, |
| 388 | + 'end_ntp' : eb.end_ntp |
| 389 | + }) |
| 390 | + ); |
| 391 | + _this.setInOutBindings(); |
| 392 | + } |
389 | 393 | } |
390 | 394 | //if in a sequence we have no need for insertDesc |
391 | 395 | if( !_this.p_seqObj){ |
Index: trunk/phase3/js2/mwEmbed/skins/ctrlBuilder.js |
— | — | @@ -364,7 +364,7 @@ |
365 | 365 | '<p class="short_match vo_showcode"><a href="#"><span>'+gM('mwe-share')+'</span></a></p>'; |
366 | 366 | |
367 | 367 | //link to the stream page if we are not already there: |
368 | | - if( ctrlObj.embedObj.roe && typeof mv_stream_interface == 'undefined' ) |
| 368 | + if( ( ctrlObj.embedObj.roe || ctrlObj.embedObj.linkback ) && typeof mv_stream_interface == 'undefined' ) |
369 | 369 | o+='<p class="short_match"><a href="javascript:$j(\'#'+ctrlObj.id+'\').get(0).doLinkBack()"><span><strong>Source Page</strong></span></a></p>'; |
370 | 370 | |
371 | 371 | o+='</div>'+ |
Index: trunk/phase3/js2/mwEmbed/libEmbedVideo/embedVideo.js |
— | — | @@ -1665,17 +1665,19 @@ |
1666 | 1666 | doLinkBack:function(){ |
1667 | 1667 | if(this.roe && this.media_element.addedROEData==false){ |
1668 | 1668 | var _this = this; |
1669 | | - this.displayHTML(gM('mwe-loading_txt')); |
| 1669 | + this.displayHTML( gM('mwe-loading_txt') ); |
1670 | 1670 | do_request(this.roe, function(data) |
1671 | 1671 | { |
1672 | 1672 | _this.media_element.addROE(data); |
1673 | 1673 | _this.doLinkBack(); |
1674 | 1674 | }); |
1675 | 1675 | }else{ |
1676 | | - if(this.media_element.linkback){ |
| 1676 | + if( this.linkback){ |
| 1677 | + window.location = this.linkback; |
| 1678 | + }else if(this.media_element.linkback){ |
1677 | 1679 | window.location = this.media_element.linkback; |
1678 | 1680 | }else{ |
1679 | | - this.displayHTML(gM('mwe-could_not_find_linkback')); |
| 1681 | + this.displayHTML( gM('mwe-could_not_find_linkback') ); |
1680 | 1682 | } |
1681 | 1683 | } |
1682 | 1684 | }, |
— | — | @@ -1703,6 +1705,7 @@ |
1704 | 1706 | $cpTxt.click(function(){ |
1705 | 1707 | $j(this).get(0).select(); |
1706 | 1708 | }); |
| 1709 | + |
1707 | 1710 | //add copy binding: |
1708 | 1711 | $cpBtn.click(function(){ |
1709 | 1712 | $cpTxt.focus().get(0).select(); |