Index: branches/MwEmbedStandAlone/modules/SmilPlayer/mw.SmilBuffer.js |
— | — | @@ -414,7 +414,7 @@ |
415 | 415 | } |
416 | 416 | }, |
417 | 417 | /** |
418 | | - * once browsers work better with seeks we can use this code: |
| 418 | + * Do a seek and issue the callback once loaded |
419 | 419 | */ |
420 | 420 | mediaBufferSeek: function ( smilElement, seekTime, callback ){ |
421 | 421 | var _this = this; |
— | — | @@ -443,7 +443,9 @@ |
444 | 444 | mw.log("SmilBuffer::mediaBufferSeek: DONE for:" + assetId + ' time:' + media.currentTime ); |
445 | 445 | |
446 | 446 | // TODO Would be great if browsers supported a mode to "stop" loading once we reach a given time |
447 | | - |
| 447 | + // probably have to adapt something like: |
| 448 | + // http://blog.pearce.org.nz/2010/11/how-to-stop-video-or-audio-element.html |
| 449 | + |
448 | 450 | if( callback ) |
449 | 451 | callback(); |
450 | 452 | callback = null; |
Index: branches/MwEmbedStandAlone/modules/Sequencer/loader.js |
— | — | @@ -7,7 +7,13 @@ |
8 | 8 | |
9 | 9 | // Loader configuration options ( all runtime options are stored in mw.SequencerConfig.js ) |
10 | 10 | mw.setDefaultConfig({ |
11 | | - 'Sequencer.KalturaPlayerEditOverlay' : false |
| 11 | + |
| 12 | + // Extends the embedPlayer sequencer clips to include attribution 'edit sequence' link on pause |
| 13 | + 'Sequencer.KalturaPlayerEditOverlay' : false, |
| 14 | + |
| 15 | + // If the sequencer should use swam transport urls for audio and video. |
| 16 | + // this can be helpful for a large local cache. |
| 17 | + 'Sequencer.UseSwamTransport' : false |
12 | 18 | }); |
13 | 19 | |
14 | 20 | |
— | — | @@ -127,7 +133,7 @@ |
128 | 134 | classRequest.push('mw.style.SequencerRemote'); |
129 | 135 | } |
130 | 136 | } |
131 | | - }) |
| 137 | + }); |
132 | 138 | |
133 | 139 | |
134 | 140 | } )( window.mw ); |
Index: branches/MwEmbedStandAlone/modules/Sequencer/mw.SequencerTimeline.js |
— | — | @@ -27,7 +27,7 @@ |
28 | 28 | timelineMode: 'clip', |
29 | 29 | |
30 | 30 | // The smil track to use as the timeline when in clip mode |
31 | | - // ( when in "time" mode we have a uniform pixle to time mapping ) |
| 31 | + // ( when in "time" mode we have a uniform pixel to time mapping ) |
32 | 32 | clipModeTrackIndex: 0, |
33 | 33 | |
34 | 34 | // The base left side offset for the clickable timeline |
— | — | @@ -167,7 +167,7 @@ |
168 | 168 | var smilClipDur = smil.getBody().getClipDuration( smilElement ); |
169 | 169 | var startOffset = $j( smilElement ).data('startOffset'); |
170 | 170 | if( playTime > startOffset && playTime < (startOffset + smilClipDur) ){ |
171 | | - // get the base pixle offset: |
| 171 | + // get the base pixel offset: |
172 | 172 | pixleOffset = _this.clickableTimelineBaseOffset + ( _this.timelineThumbLayout.totalWidth * clipInx ) ; |
173 | 173 | // add relative time offset: |
174 | 174 | pixleOffset += ( ( playTime - startOffset ) / smilClipDur ) * _this.timelineThumbLayout.totalWidth; |
— | — | @@ -260,7 +260,7 @@ |
261 | 261 | $j('<div />') |
262 | 262 | .css({ |
263 | 263 | 'position' : 'absolute', |
264 | | - 'top' : '10px', |
| 264 | + 'top' : '0px', |
265 | 265 | 'height' : '100%', |
266 | 266 | 'width' : 2, |
267 | 267 | 'background-color' : '#AAF' |
— | — | @@ -1006,7 +1006,7 @@ |
1007 | 1007 | 'opacity' : '.9', |
1008 | 1008 | 'left': '0px', |
1009 | 1009 | 'height': _this.timelineThumbLayout.height |
1010 | | - }) |
| 1010 | + } ) |
1011 | 1011 | .attr( 'src', smil.getAssetUrl( smilElement.attr('poster') ) ) |
1012 | 1012 | .load( function(){ |
1013 | 1013 | if( $thumbTarget.children().length == 0 ){ |
— | — | @@ -1017,7 +1017,7 @@ |
1018 | 1018 | // Sometimes the load event does not fire. Force the fallback image after 5 seconds |
1019 | 1019 | setTimeout( function(){ |
1020 | 1020 | if( $thumbTarget.children().length == 0 ){ |
1021 | | - mw.log( "SequencerTimeline::drawClipThumb: force image fallabck:: " + img.src); |
| 1021 | + mw.log( "SequencerTimeline::drawClipThumb: timeout, force image fallabck:: " + img.src); |
1022 | 1022 | $thumbTarget.html( img ); |
1023 | 1023 | if( callback ){ |
1024 | 1024 | callback(); |
— | — | @@ -1031,7 +1031,7 @@ |
1032 | 1032 | smil.getBuffer().bufferedSeekRelativeTime( smilElement, relativeTime, function(){ |
1033 | 1033 | // Add the seek, Add to canvas and draw thumb request |
1034 | 1034 | smil.getLayout().drawSmilElementToTarget( smilElement, $thumbTarget, relativeTime, function(){ |
1035 | | - //mw.log("SequencerTimeline:: Done drawSmilElementToTarget " + $j( smilElement ).attr('id') + ' cb:' + callback); |
| 1035 | + // mw.log("SequencerTimeline:: Done drawSmilElementToTarget " + $j( smilElement ).attr('id') + ' cb:' + callback); |
1036 | 1036 | // Run the callback and un-set it for the current closure |
1037 | 1037 | if( callback ){ |
1038 | 1038 | callback(); |
— | — | @@ -1059,7 +1059,7 @@ |
1060 | 1060 | |
1061 | 1061 | if( $j( smilSequenceTrack).attr('tracktype') == 'audio' ){ |
1062 | 1062 | $trackNameTitle.append( |
1063 | | - $j('<span />').addClass( 'ui-icon ui-icon-volume-on'), |
| 1063 | + $j('<span />').addClass( 'ui-icon ui-icon-volume-on' ), |
1064 | 1064 | $j('<span />').text( gM( 'mwe-sequencer-audio-track' ) ) |
1065 | 1065 | ); |
1066 | 1066 | } else { |
— | — | @@ -1069,6 +1069,7 @@ |
1070 | 1070 | $j('<span />').text( gM( 'mwe-sequencer-video-track' ) ) |
1071 | 1071 | ); |
1072 | 1072 | } |
| 1073 | + |
1073 | 1074 | // Set track name height |
1074 | 1075 | $trackNameContainer.css({ |
1075 | 1076 | 'height' : this.getSequenceTrackHeight( smilSequenceTrack ) |
Index: branches/MwEmbedStandAlone/modules/Sequencer/remotes/mw.MediaWikiRemoteSequencer.js |
— | — | @@ -79,12 +79,12 @@ |
80 | 80 | setTimeout(function(){ |
81 | 81 | $j( embedPlayer ).siblings( '.kalturaEditOverlay' ).fadeOut( 'fast' ); |
82 | 82 | embedPlayer.$interface.find('.k-menu').fadeIn('fast'); |
83 | | - }, 3500) |
| 83 | + }, 3500); |
84 | 84 | |
85 | 85 | // On end runs before interface bindings (give the dom 10ms to build out the menu ) |
86 | 86 | setTimeout(function(){ |
87 | 87 | $j( embedPlayer ).siblings( '.k-menu' ).hide(); |
88 | | - },10) |
| 88 | + }, 10); |
89 | 89 | }); |
90 | 90 | $j( embedPlayer ).bind( 'play', function(){ |
91 | 91 | $j( embedPlayer ).siblings( '.kalturaEditOverlay' ).fadeOut( 'fast' ); |
— | — | @@ -111,7 +111,7 @@ |
112 | 112 | if(! $j( '#' + embedPlayerId ).siblings( '.kalturaEditOverlay' ).length ){ |
113 | 113 | |
114 | 114 | var seqTitle = embedPlayer.apiTitleKey |
115 | | - .replace( 'Sequence-', 'Sequence:') |
| 115 | + .replace( 'Sequence-', 'Sequence:'); |
116 | 116 | // strip the extension |
117 | 117 | seqTitle = seqTitle.substr(0, seqTitle.length -4 ); |
118 | 118 | // not ideal details page builder but 'should work' :: |
— | — | @@ -199,7 +199,7 @@ |
200 | 200 | |
201 | 201 | $j( '#' + embedPlayerId ).siblings( '.kalturaEditOverlay' ) |
202 | 202 | .fadeIn('fast'); |
203 | | -} |
| 203 | +}; |
204 | 204 | mw.MediaWikiRemoteSequencer = function( options ) { |
205 | 205 | return this.init( options ); |
206 | 206 | }; |
— | — | @@ -240,7 +240,7 @@ |
241 | 241 | .click(function(){ |
242 | 242 | _this.showEditor(); |
243 | 243 | return false; |
244 | | - }) |
| 244 | + }); |
245 | 245 | |
246 | 246 | $j( this.target ).html( |
247 | 247 | gM("mwe-sequencer-no-sequence-create", |
— | — | @@ -257,7 +257,7 @@ |
258 | 258 | .click(function(){ |
259 | 259 | _this.showEditor(); |
260 | 260 | return false; |
261 | | - }) |
| 261 | + }); |
262 | 262 | |
263 | 263 | _this.displayPlayerEmbed(); |
264 | 264 | } |
— | — | @@ -271,7 +271,7 @@ |
272 | 272 | .click(function(){ |
273 | 273 | _this.showEditor(); |
274 | 274 | return false; |
275 | | - }) |
| 275 | + }); |
276 | 276 | }, |
277 | 277 | |
278 | 278 | showEditUI: function(){ |
— | — | @@ -310,7 +310,7 @@ |
311 | 311 | displayPlayerEmbed: function(){ |
312 | 312 | var _this = this; |
313 | 313 | // load the embedPlayer module: |
314 | | - mw.load('EmbedPlayer', function(){ |
| 314 | + mw.load( 'EmbedPlayer', function(){ |
315 | 315 | // Check if the sequence has been flattened and is up to date: |
316 | 316 | var request = { |
317 | 317 | 'action': 'query', |
— | — | @@ -334,7 +334,7 @@ |
335 | 335 | ) |
336 | 336 | ) |
337 | 337 | .addClass( 'ui-state-highlight' ) |
338 | | - ) |
| 338 | + ); |
339 | 339 | } else { |
340 | 340 | for( var pageId in data.query.pages) { |
341 | 341 | var page = data.query.pages[ pageId ]; |
— | — | @@ -353,7 +353,7 @@ |
354 | 354 | }).css('cursor', 'pointer') |
355 | 355 | ) |
356 | 356 | ).addClass( 'ui-state-highlight' ) |
357 | | - ) |
| 357 | + ); |
358 | 358 | } |
359 | 359 | } |
360 | 360 | if( page.imageinfo && page.imageinfo[0] ){ |
— | — | @@ -401,7 +401,7 @@ |
402 | 402 | $j( _this.target ).empty().append( |
403 | 403 | $j('<div />') |
404 | 404 | .addClass( 'sequencer-player') |
405 | | - .css( { |
| 405 | + .css({ |
406 | 406 | 'float' : 'left', |
407 | 407 | 'width' : width |
408 | 408 | }) |
— | — | @@ -441,7 +441,7 @@ |
442 | 442 | // Add a clear both to give content body height |
443 | 443 | $j('<div />').css( { 'clear': 'both' } ) |
444 | 444 | |
445 | | - ) |
| 445 | + ); |
446 | 446 | // add cat links if set; |
447 | 447 | if( _this.catLinks ){ |
448 | 448 | $j( _this.target ).append( |
Index: branches/MwEmbedStandAlone/remotes/mediaWiki.js |
— | — | @@ -4,7 +4,7 @@ |
5 | 5 | */ |
6 | 6 | var urlparts = getRemoteEmbedPath(); |
7 | 7 | var mwEmbedHostPath = urlparts[0]; |
8 | | -var mwRemoteVersion = 'r182'; |
| 8 | +var mwRemoteVersion = 'r183'; |
9 | 9 | var mwUseScriptLoader = true; |
10 | 10 | |
11 | 11 | // Log the mwRemote version makes it easy to debug cache issues |