Index: branches/js2-work/phase3/js/mwEmbed/skins/ctrlBuilder.js |
— | — | @@ -567,20 +567,27 @@ |
568 | 568 | * Hide the control bar. |
569 | 569 | */ |
570 | 570 | hideControlBar : function(){ |
| 571 | + var animateDuration = 'slow' |
571 | 572 | // Else hide the control bar ( if checkOverlayControls is still true ) |
572 | | - this.embedPlayer.$interface.find( '.control-bar').fadeOut( 'slow' ); |
573 | | - // Move down itext if present |
574 | | - $j( '.itext' ).animate( {'bottom' : 10 } ); |
| 573 | + this.embedPlayer.$interface.find( '.control-bar').fadeOut( animateDuration ); |
| 574 | + this.embedPlayer.$interface.find( '.itext' ).animate( { |
| 575 | + 'bottom' : 10 |
| 576 | + }, animateDuration ); |
| 577 | + |
575 | 578 | }, |
576 | 579 | |
577 | 580 | /** |
578 | 581 | * Show the control bar |
579 | 582 | */ |
580 | 583 | showControlBar : function(){ |
| 584 | + var animateDuration = 'slow' |
581 | 585 | // Show controls |
582 | | - this.embedPlayer.$interface.find( '.control-bar').fadeIn( 'slow' ); |
| 586 | + this.embedPlayer.$interface.find( '.control-bar').fadeIn( animateDuration ); |
583 | 587 | // Move up itext if present |
584 | | - $j( '.itext' ).animate( { 'bottom' : this.getHeight() + 10 } ); |
| 588 | + this.embedPlayer.$interface.find( '.itext' ).animate( { |
| 589 | + 'bottom' : this.getHeight() + 10 |
| 590 | + }, animateDuration ); |
| 591 | + |
585 | 592 | }, |
586 | 593 | |
587 | 594 | /** |
Index: branches/js2-work/phase3/js/mwEmbed/modules/TimedText/mw.TimedText.js |
— | — | @@ -1244,8 +1244,8 @@ |
1245 | 1245 | 'prop':'revisions' |
1246 | 1246 | }; |
1247 | 1247 | mw.getJSON( this.apiUrl, request, function( sourcePages ) { |
1248 | | - //If "timedText" is not a valid namespace try "just" with prefix: |
1249 | | - if ( sourcePages.error && sourcePages.error.code == 'apunknown_apnamespace' ) { |
| 1248 | + // If "timedText" is not a valid namespace try "just" with prefix: |
| 1249 | + if ( sourcePages.error && sourcePages.error.code == 'apunknown_apnamespace' ) { |
1250 | 1250 | var request = { |
1251 | 1251 | 'list' : 'allpages', |
1252 | 1252 | 'apprefix' : _this.getCanonicalTimedTextNS() + ':' + _this.embedPlayer.apiTitleKey |
Index: branches/js2-work/phase3/js/mwEmbed/modules/EmbedPlayer/loader.js |
— | — | @@ -64,8 +64,6 @@ |
65 | 65 | * |
66 | 66 | * NOTE: this function can be part of setup can run prior to jQuery being ready |
67 | 67 | */ |
68 | | - |
69 | | - |
70 | 68 | mw.documentHasPlayerTags = function() { |
71 | 69 | var rewriteTags = mw.getConfig( 'rewritePlayerTags' ); |
72 | 70 | if( rewriteTags ) { |
— | — | @@ -100,8 +98,6 @@ |
101 | 99 | |
102 | 100 | // Tell mwEmbed to run setup |
103 | 101 | mw.setConfig( 'runSetupMwEmbed', true ); |
104 | | - |
105 | | - mw.log(" run setup is: " + mw.getConfig( 'runSetupMwEmbed' ) ); |
106 | 102 | } |
107 | 103 | }); |
108 | 104 | |
— | — | @@ -129,9 +125,6 @@ |
130 | 126 | '$j.ui.slider' |
131 | 127 | ] |
132 | 128 | ]; |
133 | | - |
134 | | - |
135 | | - |
136 | 129 | |
137 | 130 | var addTimedTextReqFlag = false; |
138 | 131 | |
— | — | @@ -177,14 +170,14 @@ |
178 | 171 | } |
179 | 172 | |
180 | 173 | // Add PNG fix code needed: |
181 | | - if ( $j.browser.msie || $j.browser.version < 7 ) { |
| 174 | + if ( $j.browser.msie && $j.browser.version < 7 ) { |
182 | 175 | dependencyRequest[0].push( '$j.fn.pngFix' ); |
183 | 176 | } |
184 | 177 | |
185 | 178 | // Do short detection, to avoid extra player library request in ~most~ cases. |
186 | 179 | //( If browser is firefox include native, if browser is IE include java ) |
187 | 180 | if( $j.browser.msie ) { |
188 | | - dependencyRequest[0].push( 'javaEmbed' ) |
| 181 | + dependencyRequest[0].push( 'javaEmbed' ) |
189 | 182 | } |
190 | 183 | |
191 | 184 | // Safari gets slower load since we have to detect ogg support |
Index: branches/js2-work/phase3/js/mwEmbed/modules/EmbedPlayer/javaEmbed.js |
— | — | @@ -7,8 +7,8 @@ |
8 | 8 | |
9 | 9 | var javaEmbed = { |
10 | 10 | |
11 | | - // instance name: |
12 | | - instanceOf:'javaEmbed', |
| 11 | + // Instance name: |
| 12 | + instanceOf: 'javaEmbed', |
13 | 13 | |
14 | 14 | // Supported feature set of the cortado applet: |
15 | 15 | supports: { |
Index: branches/js2-work/phase3/js/mwEmbed/mwEmbed.js |
— | — | @@ -2901,7 +2901,10 @@ |
2902 | 2902 | mwCheckBody(); |
2903 | 2903 | }, 250); |
2904 | 2904 | |
2905 | | -// If window.jQuery is already avaliable set no conflict before setup |
| 2905 | +// If window.jQuery is already avaliable set mapping before setup |
| 2906 | +// ( we don't use noConflict since other pages that include |
| 2907 | +// mwEmbed may depend on $ = jQuery, with a simple |
| 2908 | +// alias we should be fine |
2906 | 2909 | if( window.jQuery ){ |
2907 | | - window['$j'] = jQuery.noConflict(); |
| 2910 | + window['$j'] = jQuery(); |
2908 | 2911 | } |
\ No newline at end of file |