r68377 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r68376‎ | r68377 | r68378 >
Date:20:48, 21 June 2010
Author:catrope
Status:deferred
Tags:
Comment:
resourceloader: Add code for grabbing all loader files
Modified paths:
  • /branches/resourceloader/phase3/includes/ResourceLoader.php (modified) (history)

Diff [purge]

Index: branches/resourceloader/phase3/includes/ResourceLoader.php
@@ -114,6 +114,19 @@
115115 return $retval;
116116 }
117117
 118+ public function getLoaderJS() {
 119+ $retval = '';
 120+ foreach ( self::$modules as $name => $module ) {
 121+ // TODO: file_get_contents() errors?
 122+ $retval .= file_get_contents( $module['loader'] );
 123+ }
 124+ // FIXME: Duplicated; centralize in doJSTransforms() or something?
 125+ if ( $this->useJSMin ) {
 126+ $retval = $this->jsMin( $retval );
 127+ }
 128+ return $retval;
 129+ }
 130+
118131 public function jsMin( $js ) {
119132 // TODO: Implement
120133 return $js;

Status & tagging log