Index: branches/REL1_17/phase3/resources/mediawiki/mediawiki.js |
— | — | @@ -323,6 +323,8 @@ |
324 | 324 | var suspended = true; |
325 | 325 | // Flag inidicating that document ready has occured |
326 | 326 | var ready = false; |
| 327 | + // Marker element for adding dynamic styles |
| 328 | + var $marker = $( 'head meta[name=ResourceLoaderDynamicStyles]' ); |
327 | 329 | |
328 | 330 | /* Private Methods */ |
329 | 331 | |
— | — | @@ -480,16 +482,15 @@ |
481 | 483 | } |
482 | 484 | // Add style sheet to document |
483 | 485 | if ( typeof registry[module].style === 'string' && registry[module].style.length ) { |
484 | | - $( 'head' ) |
485 | | - .append( mediaWiki.html.element( 'style', |
486 | | - { type: "text/css" }, |
| 486 | + $marker.before( mediaWiki.html.element( 'style', |
| 487 | + { type: 'text/css' }, |
487 | 488 | new mediaWiki.html.Cdata( registry[module].style ) |
488 | 489 | ) ); |
489 | 490 | } else if ( typeof registry[module].style === 'object' |
490 | 491 | && !( registry[module].style instanceof Array ) ) |
491 | 492 | { |
492 | 493 | for ( var media in registry[module].style ) { |
493 | | - $( 'head' ).append( mediaWiki.html.element( 'style', |
| 494 | + $marker.before( mediaWiki.html.element( 'style', |
494 | 495 | { type: 'text/css', media: media }, |
495 | 496 | new mediaWiki.html.Cdata( registry[module].style[media] ) |
496 | 497 | ) ); |
Property changes on: branches/REL1_17/phase3/resources/mediawiki/mediawiki.js |
___________________________________________________________________ |
Added: svn:mergeinfo |
497 | 498 | Merged /branches/sqlite/resources/mediawiki/mediawiki.js:r58211-58321 |
498 | 499 | Merged /trunk/phase3/resources/mediawiki/mediawiki.js:r78943 |
499 | 500 | Merged /branches/new-installer/phase3/resources/mediawiki/mediawiki.js:r43664-66004 |
500 | 501 | Merged /branches/REL1_15/phase3/resources/mediawiki/mediawiki.js:r51646 |