Index: trunk/extensions/MetavidWiki/skins/mv_stream.js |
— | — | @@ -62,8 +62,7 @@ |
63 | 63 | mvJsLoader.doLoad({ |
64 | 64 | '$j.autocomplete':'jquery/plugins/jquery.autocomplete.js', |
65 | 65 | '$j.fn.hoverIntent':'jquery/plugins/jquery.hoverIntent.js', |
66 | | - '$j.ui.resizable':'jquery/plugins/ui.resizable.js', |
67 | | - '$j.ui.draggable':'jquery/plugins/ui.draggable.js' |
| 66 | + '$j.ui.resizable':'jquery/jquery.ui-1.5.2/ui/minified/ui.resizable.min.js' |
68 | 67 | },function(){ |
69 | 68 | //now extend draggable |
70 | 69 | mvJsLoader.doLoad({ |
— | — | @@ -272,10 +271,12 @@ |
273 | 272 | /* based on a a mvd_id update the video thumbnail to the correct location |
274 | 273 | */ |
275 | 274 | doRestore:function(){ |
| 275 | + js_log('f:doRestore'); |
276 | 276 | var vid_elm = $j('#embed_vid').get(0); |
277 | 277 | if(vid_elm){ |
278 | 278 | if( vid_elm.isPlaying()){ |
279 | | - //js_log('vid elm is playing delay restore:') |
| 279 | + js_log('vid elm is playing delay restore:') |
| 280 | + if(!vid_elm.userSlide) //dont' restore if userSlide is true |
280 | 281 | setTimeout("mv_init_interface.doRestore()", 500); |
281 | 282 | }else{ |
282 | 283 | //only restore if onClipDone_disp is false |
— | — | @@ -464,6 +465,7 @@ |
465 | 466 | div.innerHTML=global_loading_txt; |
466 | 467 | } |
467 | 468 | //free the editor slot: |
| 469 | + js_log('mv_disp_mvd: nset mv_open_edit_mvd'); |
468 | 470 | mv_open_edit_mvd=null; |
469 | 471 | function f( request ) { |
470 | 472 | result= request.responseText; |
— | — | @@ -503,29 +505,15 @@ |
504 | 506 | /* non-ajax preview of clip adjustment*/ |
505 | 507 | function mv_adjust_preview(mvd_id){ |
506 | 508 | mv_lock_vid_updates=true; |
507 | | - //if(!$('mv_start_hr_'+mvd_id))return ; |
508 | | - //if(!$('mv_end_hr_'+mvd_id))return ; |
509 | | - //if(!$('embed_vid'))return ; |
510 | | - //if mv_embed state is "playing" swap preview button per html5 spec: |
511 | | - if($j('#embed_vid').get(0).isPlaying()){ |
512 | | - //do stop swap preview button back |
513 | | - $j('#embed_vid').get(0).stop(); |
514 | | - } |
515 | | - //first time set up |
516 | | - //if(!golobal_org_ptext)golobal_org_ptext = $j('#wpPreview_'+mvd_id).val(); |
517 | | - //js_log('gptext: ' + golobal_org_ptext); |
518 | | - //if($j('#wpPreview_'+mvd_id).val()!=$j('#wpPreview_stop_msg_'+mvd_id).val() ){ |
519 | | - //preview request set text to hidden stop text: |
520 | | - //$j('#wpPreview_'+mvd_id).val( $j('#wpPreview_stop_msg_'+mvd_id).val() ) ; |
521 | | - //update the video source |
| 509 | + |
522 | 510 | js_log('start val:#mv_start_hr_'+mvd_id+' ' + $j('#mv_start_hr_'+mvd_id).val() + ' end:'+ $j('#mv_end_hr_'+mvd_id).val() ); |
| 511 | + |
| 512 | + $j('#embed_vid').get(0).stop(); |
| 513 | + |
523 | 514 | do_video_time_update($j('#mv_start_hr_'+mvd_id).val(), $j('#mv_end_hr_'+mvd_id).val() ); |
524 | 515 | //start playing |
525 | | - mv_do_play(); |
526 | | - //}else{ |
527 | | - //(video should already be stooped). restore org ptext: |
528 | | - // $j('#wpPreview_'+mvd_id).val(golobal_org_ptext); |
529 | | - //} |
| 516 | + $j('#embed_vid').get(0).play(); |
| 517 | + |
530 | 518 | mv_lock_vid_updates=false; |
531 | 519 | } |
532 | 520 | /* |
— | — | @@ -839,10 +827,12 @@ |
840 | 828 | $j(setHtmlId).html( result) ; |
841 | 829 | scroll_to_pos(mvd_id); |
842 | 830 | } |
843 | | - //unlock the interface updates |
844 | | - mv_lock_vid_updates=false; |
845 | | - //free the editor slot: |
846 | | - mv_open_edit_mvd=null; |
| 831 | + if(edit_action!='preview'){ |
| 832 | + //unlock the interface updates |
| 833 | + mv_lock_vid_updates=false; |
| 834 | + //free the editor slot: |
| 835 | + mv_open_edit_mvd=null; |
| 836 | + } |
847 | 837 | } |
848 | 838 | //return false to prevent the form being submitted |
849 | 839 | return false; |
Index: trunk/extensions/MetavidWiki/skins/mv_embed/embedLibs/mv_flashEmbed.js |
— | — | @@ -153,8 +153,14 @@ |
154 | 154 | } |
155 | 155 | }, |
156 | 156 | monitor : function() |
157 | | - { |
158 | | - this.getFLA(); |
| 157 | + { |
| 158 | + //do monitor update: |
| 159 | + if( ! this.monitorTimerId ){ |
| 160 | + if(document.getElementById(this.id)){ |
| 161 | + this.monitorTimerId = setInterval('$j(\'#'+this.id+'\').get(0).monitor()', 250); |
| 162 | + } |
| 163 | + } |
| 164 | + this.getFLA(); |
159 | 165 | if(!this.fla['getTime']) |
160 | 166 | return js_log('can not monitor without time'); |
161 | 167 | |
— | — | @@ -179,20 +185,13 @@ |
180 | 186 | this.setStatus( seconds2ntp(this.currentTime) + '/' + end_ntp); |
181 | 187 | this.setSliderValue((this.currentTime - ntp2seconds(start_ntp)) / (ntp2seconds(end_ntp)-ntp2seconds(start_ntp)) ); |
182 | 188 | } |
183 | | - } |
184 | | - //do monitor update: |
185 | | - if( ! this.monitorTimerId ){ |
186 | | - if(document.getElementById(this.id)){ |
187 | | - this.monitorTimerId = setInterval('$j(\'#'+this.id+'\').get(0).monitor()', 250); |
188 | | - } |
189 | | - } |
| 189 | + } |
190 | 190 | |
191 | 191 | //super hackery to see if we have "probably" reached the end of playback: |
192 | 192 | if(this.prevTime==this.currentTime && (this.currentTime > (ntp2seconds(end_ntp)-1)) ){ |
193 | 193 | js_log('probablly reached end of stream: '+this.currentTime); |
194 | 194 | this.onClipDone(); |
195 | | - } |
196 | | - |
| 195 | + } |
197 | 196 | this.prevTime = this.currentTime; |
198 | 197 | |
199 | 198 | //js_log('cur perc loaded: ' + this.fla.getPercentLoaded() +' cur time : ' + (this.currentTime - ntp2seconds(start_ntp)) +' / ' +(ntp2seconds(end_ntp)-ntp2seconds(start_ntp))); |
— | — | @@ -225,6 +224,8 @@ |
226 | 225 | if( ! this.startedTimedPlayback){ |
227 | 226 | js_log('clip done before timed playback started .. not good. (ignoring) '); |
228 | 227 | //setTimeout('$j(\'#'+embed.id+'\').get(0).play()', 250); |
| 228 | + //keep monitoring: |
| 229 | + this.monitor(); |
229 | 230 | }else{ |
230 | 231 | js_log('clip done and '+ this.startedTimedPlayback); |
231 | 232 | //stop the clip if its not stoped already: |
Index: trunk/extensions/MetavidWiki/skins/mv_embed/mv_embed.js |
— | — | @@ -531,12 +531,8 @@ |
532 | 532 | var _this = embedObj; |
533 | 533 | //add in drag/seek hooks: |
534 | 534 | if(!_this.base_seeker_slider_offset && $j('#mv_seeker_slider_'+_this.id).get(0)) |
535 | | - _this.base_seeker_slider_offset = $j('#mv_seeker_slider_'+_this.id).get(0).offsetLeft; |
| 535 | + _this.base_seeker_slider_offset = $j('#mv_seeker_slider_'+_this.id).get(0).offsetLeft; |
536 | 536 | |
537 | | - //if playlist always start at 0 |
538 | | - _this.start_time_sec = (_this.instanceOf == 'mvPlayList')?0: |
539 | | - _this.start_time_sec = ntp2seconds(_this.getTimeReq().split('/')[0]); |
540 | | - |
541 | 537 | //js_log('looking for: #mv_seeker_slider_'+_this.id + "\n " + |
542 | 538 | // 'start sec: '+_this.start_time_sec + ' base offset: '+_this.base_seeker_slider_offset); |
543 | 539 | |
— | — | @@ -551,6 +547,9 @@ |
552 | 548 | var options = ui.options; |
553 | 549 | //remove "play button" |
554 | 550 | $j('#big_play_link_'+_this.id).fadeOut('fast'); |
| 551 | + //if playlist always start at 0 |
| 552 | + _this.start_time_sec = (_this.instanceOf == 'mvPlayList')?0: |
| 553 | + _this.start_time_sec = ntp2seconds(_this.getTimeReq().split('/')[0]); |
555 | 554 | }, |
556 | 555 | drag:function(e, ui){ |
557 | 556 | //@@todo get the -14 number from the skin somehow |
Index: trunk/extensions/MetavidWiki/skins/mv_embed/mv_playlist.js |
— | — | @@ -1679,11 +1679,11 @@ |
1680 | 1680 | $j('#'+tObj.overlay_selector_id).show(); |
1681 | 1681 | |
1682 | 1682 | //do update: |
1683 | | - /*js_log('doing update for: '+ tObj.pClip.id + |
| 1683 | + js_log('doing update for: '+ tObj.pClip.id + |
1684 | 1684 | ' type:' + tObj.transAttrType + |
1685 | 1685 | ' t_type:'+ tObj.type + |
1686 | 1686 | ' subypte:'+ tObj.subtype + |
1687 | | - ' percent:' + percent);*/ |
| 1687 | + ' percent:' + percent); |
1688 | 1688 | |
1689 | 1689 | this['type'][tObj.type][tObj.subtype].u(tObj,percent); |
1690 | 1690 | }, |