r72007 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r72006‎ | r72007 | r72008 >
Date:02:28, 31 August 2010
Author:catrope
Status:deferred
Tags:
Comment:
resourceloader: Make ResourceLoaderModule an abstract class that only implements getName()/setName() and provides a generic interface for modules. Move all the code specific to dealing with files (everything except getName()/setName()) to a subclass called ResourceLoaderFileModule. This reduces the number of dummy functions in ResourceLoaderSiteJSModule (which continues to extend ResourceLoaderModule) by about half.
Modified paths:
  • /branches/resourceloader/phase3/includes/AutoLoader.php (modified) (history)
  • /branches/resourceloader/phase3/includes/ResourceLoaderModule.php (modified) (history)
  • /branches/resourceloader/phase3/resources/Resources.php (modified) (history)

Diff [purge]

Index: branches/resourceloader/phase3/includes/AutoLoader.php
@@ -198,6 +198,7 @@
199199 'ReplacementArray' => 'includes/StringUtils.php',
200200 'Replacer' => 'includes/StringUtils.php',
201201 'ResourceLoader' => 'includes/ResourceLoader.php',
 202+ 'ResourceLoaderFileModule' => 'includes/ResourceLoaderModule.php',
202203 'ResourceLoaderModule' => 'includes/ResourceLoaderModule.php',
203204 'ResourceLoaderSiteJSModule' => 'includes/ResourceLoaderModule.php',
204205 'ReverseChronologicalPager' => 'includes/Pager.php',
Index: branches/resourceloader/phase3/includes/ResourceLoaderModule.php
@@ -18,10 +18,96 @@
1919 * @author Roan Kattouw
2020 */
2121
22 -// TODO: Class comment
23 -// TODO: Add an interface to inherit from rather than having to subclass this class, or add an empty-returning superclass
24 -class ResourceLoaderModule {
 22+/**
 23+ * Interface for resource loader modules, with name registration functionality.
 24+ */
 25+abstract class ResourceLoaderModule {
2526 private $name = null;
 27+
 28+ /**
 29+ * Get this module's name. This is set when the module is registered
 30+ * with ResourceLoader::register()
 31+ * @return mixed Name (string) or null if no name was set
 32+ */
 33+ public function getName() {
 34+ return $this->name;
 35+ }
 36+
 37+ /**
 38+ * Set this module's name. This is called by ResourceLodaer::register()
 39+ * when registering the module. Other code should not call this.
 40+ * @param $name string Name
 41+ */
 42+ public function setName( $name ) {
 43+ $this->name = $name;
 44+ }
 45+
 46+ /**
 47+ * Get all JS for this module for a given language and skin.
 48+ * Includes all relevant JS except loader scripts.
 49+ * @param $lang string Language code
 50+ * @param $skin string Skin name
 51+ * @param $debug bool Whether to include debug scripts
 52+ * @return string JS
 53+ */
 54+ public abstract function getScript( $lang, $skin, $debug );
 55+
 56+ /**
 57+ * Get all CSS for this module for a given skin.
 58+ * @param $skin string Skin name
 59+ * @return string CSS
 60+ */
 61+ public abstract function getStyle( $skin );
 62+
 63+ /**
 64+ * Get the messages needed for this module.
 65+ *
 66+ * To get a JSON blob with messages, use MessageBlobStore::get()
 67+ * @return array of message keys. Keys may occur more than once
 68+ */
 69+ public abstract function getMessages();
 70+
 71+ /**
 72+ * Get the loader JS for this module, if set.
 73+ * @return mixed Loader JS (string) or false if no custom loader set
 74+ */
 75+ public abstract function getLoaderScript();
 76+
 77+ /**
 78+ * Get a list of modules this module depends on.
 79+ *
 80+ * Dependency information is taken into account when loading a module
 81+ * on the client side. When adding a module on the server side,
 82+ * dependency information is NOT taken into account and YOU are
 83+ * responsible for adding dependent modules as well. If you don't do
 84+ * this, the client side loader will send a second request back to the
 85+ * server to fetch the missing modules, which kind of defeats the
 86+ * purpose of the resource loader.
 87+ *
 88+ * To add dependencies dynamically on the client side, use a custom
 89+ * loader script, see getLoaderScript()
 90+ * @return array Array of module names (strings)
 91+ */
 92+ public abstract function getDependencies();
 93+
 94+ /**
 95+ * Get this module's last modification timestamp for a given
 96+ * combination of language, skin and debug mode flag. This is typically
 97+ * the highest of each of the relevant components' modification
 98+ * timestamps. Whenever anything happens that changes the module's
 99+ * contents for these parameters, the mtime should increase.
 100+ * @param $lang string Language code
 101+ * @param $skin string Skin name
 102+ * @param $debug bool Debug mode flag
 103+ * @return int UNIX timestamp
 104+ */
 105+ public abstract function getmtime( $lang, $skin, $debug );
 106+}
 107+
 108+/**
 109+ * Module based on local JS/CSS files. This is the most common type of module.
 110+ */
 111+class ResourceLoaderFileModule extends ResourceLoaderModule {
26112 private $scripts = array();
27113 private $styles = array();
28114 private $messages = array();
@@ -98,14 +184,6 @@
99185 }
100186 }
101187
102 - public function getName() {
103 - return $this->name;
104 - }
105 -
106 - public function setName( $name ) {
107 - $this->name = $name;
108 - }
109 -
110188 /**
111189 * Add script files to this module. In order to be valid, a module
112190 * must contain at least one script file.
@@ -215,15 +293,6 @@
216294 $this->loaders = array_merge( $this->loaders, (array)$scripts );
217295 }
218296
219 - /**
220 - * Get all JS for this module for a given language and skin. This
221 - * aggregates the output of getPrimaryScript(), getLanguageScript(),
222 - * getSkinScript() and getDebugScript() (but NOT getLoaderScript() !)
223 - * @param $lang string Language code
224 - * @param $skin string Skin name
225 - * @param $debug bool Whether to include debug scripts
226 - * @return string JS
227 - */
228297 public function getScript( $lang, $skin, $debug ) {
229298 $retval = $this->getPrimaryScript() . "\n" .
230299 $this->getLanguageScript( $lang ) . "\n" .
@@ -234,13 +303,47 @@
235304 return $retval;
236305 }
237306
 307+ public function getStyle( $skin ) {
 308+ return $this->getPrimaryStyle() . "\n" . $this->getSkinStyle( $skin );
 309+ }
 310+
 311+ public function getMessages() {
 312+ return $this->messages;
 313+ }
 314+
 315+ public function getDependencies() {
 316+ return $this->dependencies;
 317+ }
 318+
 319+ public function getLoaderScript() {
 320+ if ( count( $this->loaders ) == 0 ) {
 321+ return false;
 322+ }
 323+ return self::concatScripts( $this->loaders );
 324+ }
 325+
238326 /**
239 - * Get all CSS for this module for a given skin. This
240 - * aggregates the output of getPrimaryStyle() and getSkinStyle()
 327+ * Get the last modified timestamp of this module, which is calculated
 328+ * as the highest last modified timestamp of its constituent files and
 329+ * the files it depends on (see getFileDependencies()). Only files
 330+ * relevant to the given language and skin are taken into account, and
 331+ * files only relevant in debug mode are not taken into account when
 332+ * debug mode is off.
 333+ * @param $lang string Language code
241334 * @param $skin string Skin name
 335+ * @param $debug bool Debug mode flag
 336+ * @return int UNIX timestamp
242337 */
243 - public function getStyle( $skin ) {
244 - return $this->getPrimaryStyle() . $this->getSkinStyle( $skin );
 338+ public function getmtime( $lang, $skin, $debug ) {
 339+ $files = array_merge( $this->scripts, $this->styles,
 340+ $debug ? $this->debugScripts : array(),
 341+ isset( $this->languageScripts[$lang] ) ? (array)$this->languageScripts[$lang] : array(),
 342+ (array)self::getSkinFiles( $skin, $this->skinScripts ),
 343+ (array)self::getSkinFiles( $skin, $this->skinStyles ),
 344+ $this->loaders,
 345+ $this->getFileDependencies( $lang, $skin )
 346+ );
 347+ return max( array_map( 'filemtime', $files ) );
245348 }
246349
247350 /**
@@ -262,24 +365,6 @@
263366 }
264367
265368 /**
266 - * Get the messages added to this module with addMessages().
267 - *
268 - * To get a JSON blob with messages, use MessageBlobStore::get()
269 - * @return array of message keys. Keys may occur more than once
270 - */
271 - public function getMessages() {
272 - return $this->messages;
273 - }
274 -
275 - /**
276 - * Get the dependencies added to this module with addDependencies()
277 - * @return array of module names (strings)
278 - */
279 - public function getDependencies() {
280 - return $this->dependencies;
281 - }
282 -
283 - /**
284369 * Get the debug JS for this module. This is pulled from the script
285370 * files added through addDebugScripts()
286371 * @return string JS
@@ -335,48 +420,12 @@
336421 }
337422
338423 /**
339 - * Get the custom loader JS, if set. This is pulled from the script
340 - * files added through addLoaders()
341 - * @return mixed Loader JS (string) or false if no custom loader set
342 - */
343 - public function getLoaderScript() {
344 - if ( count( $this->loaders ) == 0 ) {
345 - return false;
346 - }
347 - return self::concatScripts( $this->loaders );
348 - }
349 -
350 - /**
351 - * Get the last modified timestamp of this module, which is calculated
352 - * as the highest last modified timestamp of its constituent files and
353 - * the files it depends on (see getFileDependencies()). Only files
354 - * relevant to the given language and skin are taken into account, and
355 - * files only relevant in debug mode are not taken into account when
356 - * debug mode is off.
357 - * @param $lang string Language code
358 - * @param $skin string Skin name
359 - * @param $debug bool Debug mode flag
360 - * @return int UNIX timestamp
361 - */
362 - public function getmtime( $lang, $skin, $debug ) {
363 - $files = array_merge( $this->scripts, $this->styles,
364 - $debug ? $this->debugScripts : array(),
365 - isset( $this->languageScripts[$lang] ) ? (array)$this->languageScripts[$lang] : array(),
366 - (array)self::getSkinFiles( $skin, $this->skinScripts ),
367 - (array)self::getSkinFiles( $skin, $this->skinStyles ),
368 - $this->loaders,
369 - $this->getFileDependencies( $lang, $skin )
370 - );
371 - return max( array_map( 'filemtime', $files ) );
372 - }
373 -
374 - /**
375424 * Get the files this module depends on indirectly for a given skin.
376425 * Currently these are only image files referenced by the module's CSS.
377426 * @param $skin string Skin name
378427 * @return array of files
379428 */
380 - public function getFileDependencies( $skin ) {
 429+ protected function getFileDependencies( $skin ) {
381430 $dbr = wfGetDb( DB_SLAVE );
382431 $deps = $dbr->selectField( 'module_deps', 'md_deps', array(
383432 'md_module' => $this->getName(),
@@ -403,7 +452,7 @@
404453 * @return string Concatenated and remapped contents of $files
405454 */
406455 protected static function concatStyles( $files ) {
407 - return implode( "\n", array_map( array( 'ResourceLoaderModule', 'remapStyle' ), array_unique( (array) $files ) ) );
 456+ return implode( "\n", array_map( array( __CLASS__, 'remapStyle' ), array_unique( (array) $files ) ) );
408457 }
409458
410459 /**
@@ -421,7 +470,7 @@
422471 * Custom module for MediaWiki:Common.js and MediaWiki:Skinname.js
423472 */
424473 class ResourceLoaderSiteJSModule extends ResourceLoaderModule {
425 - protected function getSkinScript( $skin ) {
 474+ public function getScript( $lang, $skin, $debug ) {
426475 return Skin::newFromKey( $skin )->generateUserJs();
427476 }
428477
@@ -447,14 +496,8 @@
448497 return $retval;
449498 }
450499
451 - // Dummy overrides to return emptyness
452 - // FIXME: Use a parent class with emptyness and let the normal module class inherit from that
453 - protected function getPrimaryScript() { return ''; }
454 - protected function getPrimaryStyle() { return ''; }
 500+ public function getStyle( $skin ) { return ''; }
455501 public function getMessages() { return array(); }
 502+ public function getLoaderScript() { return ''; }
456503 public function getDependencies() { return array(); }
457 - protected function getDebugScript() { return ''; }
458 - protected function getLanguageScript( $lang ) { return ''; }
459 - protected function getSkinStyle( $skin ) { return ''; }
460 - public function getLoaderScript() { return false; }
461504 }
Index: branches/resourceloader/phase3/resources/Resources.php
@@ -8,21 +8,21 @@
99
1010 /* Skins */
1111
12 - 'vector' => new ResourceLoaderModule( array( 'styles' => 'skins/vector/main-ltr.css' ) ),
 12+ 'vector' => new ResourceLoaderFileModule( array( 'styles' => 'skins/vector/main-ltr.css' ) ),
1313
1414 /* jQuery */
1515
16 - 'jquery' => new ResourceLoaderModule( array( 'scripts' => 'resources/jquery/jquery.js' ) ),
 16+ 'jquery' => new ResourceLoaderFileModule( array( 'scripts' => 'resources/jquery/jquery.js' ) ),
1717
1818 /* jQuery Plugins */
1919
20 - 'jquery.tabIndex' => new ResourceLoaderModule( array( 'scripts' => 'resources/jquery/jquery.tabIndex.js' ) ),
21 - 'jquery.cookie' => new ResourceLoaderModule( array( 'scripts' => 'resources/jquery/jquery.cookie.js' ) ),
 20+ 'jquery.tabIndex' => new ResourceLoaderFileModule( array( 'scripts' => 'resources/jquery/jquery.tabIndex.js' ) ),
 21+ 'jquery.cookie' => new ResourceLoaderFileModule( array( 'scripts' => 'resources/jquery/jquery.cookie.js' ) ),
2222
2323 /* jQuery UI */
2424
2525 // Core
26 - 'jquery.ui.core' => new ResourceLoaderModule( array(
 26+ 'jquery.ui.core' => new ResourceLoaderFileModule( array(
2727 'scripts' => 'resources/jquery.ui/jquery.ui.core.js',
2828 'skinStyles' => array(
2929 'default' => array(
@@ -36,28 +36,28 @@
3737 ),
3838 'dependencies' => 'jquery',
3939 ) ),
40 - 'jquery.ui.widget' => new ResourceLoaderModule( array(
 40+ 'jquery.ui.widget' => new ResourceLoaderFileModule( array(
4141 'scripts' => 'resources/jquery.ui/jquery.ui.widget.js',
4242 'dependencies' => 'jquery.ui.core',
4343 ) ),
44 - 'jquery.ui.mouse' => new ResourceLoaderModule( array(
 44+ 'jquery.ui.mouse' => new ResourceLoaderFileModule( array(
4545 'scripts' => 'resources/jquery.ui/jquery.ui.mouse.js',
4646 'dependencies' => 'jquery',
4747 ) ),
48 - 'jquery.ui.position' => new ResourceLoaderModule( array(
 48+ 'jquery.ui.position' => new ResourceLoaderFileModule( array(
4949 'scripts' => 'resources/jquery.ui/jquery.ui.position.js',
5050 'dependencies' => 'jquery',
5151 ) ),
5252 // Interactions
53 - 'jquery.ui.draggable' => new ResourceLoaderModule( array(
 53+ 'jquery.ui.draggable' => new ResourceLoaderFileModule( array(
5454 'scripts' => 'resources/jquery.ui/jquery.ui.draggable.js',
5555 'dependencies' => 'jquery.ui.core',
5656 ) ),
57 - 'jquery.ui.droppable' => new ResourceLoaderModule( array(
 57+ 'jquery.ui.droppable' => new ResourceLoaderFileModule( array(
5858 'scripts' => 'resources/jquery.ui/jquery.ui.droppable.js',
5959 'dependencies' => array( 'jquery.ui.core', 'jquery.ui.draggable' ),
6060 ) ),
61 - 'jquery.ui.resizable' => new ResourceLoaderModule( array(
 61+ 'jquery.ui.resizable' => new ResourceLoaderFileModule( array(
6262 'scripts' => 'resources/jquery.ui/jquery.ui.resizable.js',
6363 'skinStyles' => array(
6464 'default' => 'resources/jquery.ui/themes/default/jquery.ui.resizable.css',
@@ -65,7 +65,7 @@
6666 ),
6767 'dependencies' => 'jquery.ui.core',
6868 ) ),
69 - 'jquery.ui.selectable' => new ResourceLoaderModule( array(
 69+ 'jquery.ui.selectable' => new ResourceLoaderFileModule( array(
7070 'scripts' => 'resources/jquery.ui/jquery.ui.selectable.js',
7171 'skinStyles' => array(
7272 'default' => 'resources/jquery.ui/themes/default/jquery.ui.selectable.css',
@@ -73,12 +73,12 @@
7474 ),
7575 'dependencies' => 'jquery.ui.core',
7676 ) ),
77 - 'jquery.ui.sortable' => new ResourceLoaderModule( array(
 77+ 'jquery.ui.sortable' => new ResourceLoaderFileModule( array(
7878 'scripts' => 'resources/jquery.ui/jquery.ui.sortable.js',
7979 'dependencies' => 'jquery.ui.core',
8080 ) ),
8181 // Widgets
82 - 'jquery.ui.accordion' => new ResourceLoaderModule( array(
 82+ 'jquery.ui.accordion' => new ResourceLoaderFileModule( array(
8383 'scripts' => 'resources/jquery.ui/jquery.ui.accordion.js',
8484 'dependencies' => 'jquery.ui.core',
8585 'skinStyles' => array(
@@ -86,7 +86,7 @@
8787 'vector' => 'resources/jquery.ui/themes/vector/jquery.ui.accordion.css',
8888 ),
8989 ) ),
90 - 'jquery.ui.autocomplete' => new ResourceLoaderModule( array(
 90+ 'jquery.ui.autocomplete' => new ResourceLoaderFileModule( array(
9191 'scripts' => 'resources/jquery.ui/jquery.ui.autocomplete.js',
9292 'dependencies' => array( 'jquery.ui.core', 'jquery.ui.widget', 'jquery.ui.position' ),
9393 'skinStyles' => array(
@@ -94,7 +94,7 @@
9595 'vector' => 'resources/jquery.ui/themes/vector/jquery.ui.autocomplete.css',
9696 ),
9797 ) ),
98 - 'jquery.ui.button' => new ResourceLoaderModule( array(
 98+ 'jquery.ui.button' => new ResourceLoaderFileModule( array(
9999 'scripts' => 'resources/jquery.ui/jquery.ui.button.js',
100100 'dependencies' => array( 'jquery.ui.core', 'jquery.ui.widget' ),
101101 'skinStyles' => array(
@@ -102,7 +102,7 @@
103103 'vector' => 'resources/jquery.ui/themes/vector/jquery.ui.button.css',
104104 ),
105105 ) ),
106 - 'jquery.ui.datepicker' => new ResourceLoaderModule( array(
 106+ 'jquery.ui.datepicker' => new ResourceLoaderFileModule( array(
107107 'scripts' => 'resources/jquery.ui/jquery.ui.datepicker.js',
108108 'dependencies' => 'jquery.ui.core',
109109 'skinStyles' => array(
@@ -164,7 +164,7 @@
165165 'zh-tw' => 'resources/jquery.ui/i18n/jquery.ui.datepicker-zh-TW.js'
166166 ),
167167 ) ),
168 - 'jquery.ui.dialog' => new ResourceLoaderModule( array(
 168+ 'jquery.ui.dialog' => new ResourceLoaderFileModule( array(
169169 'scripts' => 'resources/jquery.ui/jquery.ui.dialog.js',
170170 'dependencies' => 'jquery.ui.core',
171171 'skinStyles' => array(
@@ -172,7 +172,7 @@
173173 'vector' => 'resources/jquery.ui/themes/vector/jquery.ui.dialog.css',
174174 ),
175175 ) ),
176 - 'jquery.ui.progressbar' => new ResourceLoaderModule( array(
 176+ 'jquery.ui.progressbar' => new ResourceLoaderFileModule( array(
177177 'scripts' => 'resources/jquery.ui/jquery.ui.progressbar.js',
178178 'dependencies' => 'jquery.ui.core',
179179 'skinStyles' => array(
@@ -180,7 +180,7 @@
181181 'vector' => 'resources/jquery.ui/themes/vector/jquery.ui.progressbar.css',
182182 ),
183183 ) ),
184 - 'jquery.ui.slider' => new ResourceLoaderModule( array(
 184+ 'jquery.ui.slider' => new ResourceLoaderFileModule( array(
185185 'scripts' => 'resources/jquery.ui/jquery.ui.slider.js',
186186 'dependencies' => array( 'jquery.ui.core', 'jquery.ui.widget', 'jquery.ui.mouse' ),
187187 'skinStyles' => array(
@@ -188,7 +188,7 @@
189189 'vector' => 'resources/jquery.ui/themes/vector/jquery.ui.slider.css',
190190 ),
191191 ) ),
192 - 'jquery.ui.tabs' => new ResourceLoaderModule( array(
 192+ 'jquery.ui.tabs' => new ResourceLoaderFileModule( array(
193193 'scripts' => 'resources/jquery.ui/jquery.ui.tabs.js',
194194 'dependencies' => 'jquery.ui.core',
195195 'skinStyles' => array(
@@ -197,159 +197,159 @@
198198 ),
199199 ) ),
200200 // Effects
201 - 'jquery.effects.core' => new ResourceLoaderModule( array(
 201+ 'jquery.effects.core' => new ResourceLoaderFileModule( array(
202202 'scripts' => 'resources/jquery.effects/jquery.effects.core.js',
203203 'dependencies' => 'jquery',
204204 ) ),
205 - 'jquery.effects.blind' => new ResourceLoaderModule( array(
 205+ 'jquery.effects.blind' => new ResourceLoaderFileModule( array(
206206 'scripts' => 'resources/jquery.effects/jquery.effects.blind.js',
207207 'dependencies' => 'jquery.effects.core',
208208 ) ),
209 - 'jquery.effects.bounce' => new ResourceLoaderModule( array(
 209+ 'jquery.effects.bounce' => new ResourceLoaderFileModule( array(
210210 'scripts' => 'resources/jquery.effects/jquery.effects.bounce.js',
211211 'dependencies' => 'jquery.effects.core',
212212 ) ),
213 - 'jquery.effects.clip' => new ResourceLoaderModule( array(
 213+ 'jquery.effects.clip' => new ResourceLoaderFileModule( array(
214214 'scripts' => 'resources/jquery.effects/jquery.effects.clip.js',
215215 'dependencies' => 'jquery.effects.core',
216216 ) ),
217 - 'jquery.effects.drop' => new ResourceLoaderModule( array(
 217+ 'jquery.effects.drop' => new ResourceLoaderFileModule( array(
218218 'scripts' => 'resources/jquery.effects/jquery.effects.drop.js',
219219 'dependencies' => 'jquery.effects.core',
220220 ) ),
221 - 'jquery.effects.explode' => new ResourceLoaderModule( array(
 221+ 'jquery.effects.explode' => new ResourceLoaderFileModule( array(
222222 'scripts' => 'resources/jquery.effects/jquery.effects.explode.js',
223223 'dependencies' => 'jquery.effects.core',
224224 ) ),
225 - 'jquery.effects.fold' => new ResourceLoaderModule( array(
 225+ 'jquery.effects.fold' => new ResourceLoaderFileModule( array(
226226 'scripts' => 'resources/jquery.effects/jquery.effects.fold.js',
227227 'dependencies' => 'jquery.effects.core',
228228 ) ),
229 - 'jquery.effects.highlight' => new ResourceLoaderModule( array(
 229+ 'jquery.effects.highlight' => new ResourceLoaderFileModule( array(
230230 'scripts' => 'resources/jquery.effects/jquery.effects.highlight.js',
231231 'dependencies' => 'jquery.effects.core',
232232 ) ),
233 - 'jquery.effects.pulsate' => new ResourceLoaderModule( array(
 233+ 'jquery.effects.pulsate' => new ResourceLoaderFileModule( array(
234234 'scripts' => 'resources/jquery.effects/jquery.effects.pulsate.js',
235235 'dependencies' => 'jquery.effects.core',
236236 ) ),
237 - 'jquery.effects.scale' => new ResourceLoaderModule( array(
 237+ 'jquery.effects.scale' => new ResourceLoaderFileModule( array(
238238 'scripts' => 'resources/jquery.effects/jquery.effects.scale.js',
239239 'dependencies' => 'jquery.effects.core',
240240 ) ),
241 - 'jquery.effects.shake' => new ResourceLoaderModule( array(
 241+ 'jquery.effects.shake' => new ResourceLoaderFileModule( array(
242242 'scripts' => 'resources/jquery.effects/jquery.effects.shake.js',
243243 'dependencies' => 'jquery.effects.core',
244244 ) ),
245 - 'jquery.effects.slide' => new ResourceLoaderModule( array(
 245+ 'jquery.effects.slide' => new ResourceLoaderFileModule( array(
246246 'scripts' => 'resources/jquery.effects/jquery.effects.slide.js',
247247 'dependencies' => 'jquery.effects.core',
248248 ) ),
249 - 'jquery.effects.transfer' => new ResourceLoaderModule( array(
 249+ 'jquery.effects.transfer' => new ResourceLoaderFileModule( array(
250250 'scripts' => 'resources/jquery.effects/jquery.effects.transfer.js',
251251 'dependencies' => 'jquery.effects.core',
252252 ) ),
253253
254254 /* MediaWiki */
255255
256 - 'mediawiki' => new ResourceLoaderModule( array(
 256+ 'mediawiki' => new ResourceLoaderFileModule( array(
257257 'scripts' => 'resources/mediawiki/mediawiki.js',
258258 'debugScripts' => 'resources/mediawiki/mediawiki.log.js',
259259 ) ),
260260
261261 /* MediaWiki Utilities */
262262
263 - 'mediawiki.utilities.client' => new ResourceLoaderModule( array(
 263+ 'mediawiki.utilities.client' => new ResourceLoaderFileModule( array(
264264 'scripts' => 'resources/mediawiki.util/mediawiki.utilities.client.js',
265265 ) ),
266266
267267 /* MediaWiki Legacy */
268268
269 - 'mediawiki.legacy.ajax' => new ResourceLoaderModule( array(
 269+ 'mediawiki.legacy.ajax' => new ResourceLoaderFileModule( array(
270270 'scripts' => 'skins/common/ajax.js',
271271 'messages' => array( 'watch', 'unwatch', 'watching', 'unwatching', 'tooltip-ca-watch', 'tooltip-ca-unwatch' ),
272272 'dependencies' => 'mediawiki',
273273 ) ),
274 - 'mediawiki.legacy.ajaxwatch' => new ResourceLoaderModule( array(
 274+ 'mediawiki.legacy.ajaxwatch' => new ResourceLoaderFileModule( array(
275275 'scripts' => 'skins/common/ajaxwatch.js',
276276 'dependencies' => 'mediawiki',
277277 ) ),
278 - 'mediawiki.legacy.block' => new ResourceLoaderModule( array(
 278+ 'mediawiki.legacy.block' => new ResourceLoaderFileModule( array(
279279 'scripts' => 'skins/common/block.js',
280280 'dependencies' => 'mediawiki',
281281 ) ),
282 - 'mediawiki.legacy.changepassword' => new ResourceLoaderModule( array(
 282+ 'mediawiki.legacy.changepassword' => new ResourceLoaderFileModule( array(
283283 'scripts' => 'skins/common/changepassword.js',
284284 'dependencies' => 'mediawiki',
285285 ) ),
286 - 'mediawiki.legacy.edit' => new ResourceLoaderModule( array(
 286+ 'mediawiki.legacy.edit' => new ResourceLoaderFileModule( array(
287287 'scripts' => 'skins/common/edit.js',
288288 'dependencies' => 'mediawiki',
289289 ) ),
290 - 'mediawiki.legacy.enhancedchanges' => new ResourceLoaderModule( array(
 290+ 'mediawiki.legacy.enhancedchanges' => new ResourceLoaderFileModule( array(
291291 'scripts' => 'skins/common/enhancedchanges.js',
292292 'dependencies' => 'mediawiki',
293293 ) ),
294 - 'mediawiki.legacy.config' => new ResourceLoaderModule( array(
 294+ 'mediawiki.legacy.config' => new ResourceLoaderFileModule( array(
295295 'scripts' => 'skins/common/config.js',
296296 'styles' => array( 'skins/common/config.css', 'skins/common/config-cc.css' ),
297297 'dependencies' => 'mediawiki',
298298 ) ),
299 - 'mediawiki.legacy.diff' => new ResourceLoaderModule( array(
 299+ 'mediawiki.legacy.diff' => new ResourceLoaderFileModule( array(
300300 'scripts' => 'skins/common/diff.js',
301301 'styles' => 'skins/common/diff.css',
302302 'dependencies' => 'mediawiki',
303303 ) ),
304 - 'mediawiki.legacy.history' => new ResourceLoaderModule( array(
 304+ 'mediawiki.legacy.history' => new ResourceLoaderFileModule( array(
305305 'scripts' => 'skins/common/history.js',
306306 'dependencies' => 'mediawiki',
307307 ) ),
308 - 'mediawiki.legacy.htmlform' => new ResourceLoaderModule( array(
 308+ 'mediawiki.legacy.htmlform' => new ResourceLoaderFileModule( array(
309309 'scripts' => 'skins/common/htmlform.js',
310310 'dependencies' => 'mediawiki',
311311 ) ),
312 - 'mediawiki.legacy.IEFixes' => new ResourceLoaderModule( array(
 312+ 'mediawiki.legacy.IEFixes' => new ResourceLoaderFileModule( array(
313313 'scripts' => 'skins/common/IEFixes.js',
314314 'dependencies' => 'mediawiki',
315315 ) ),
316 - 'mediawiki.legacy.metadata' => new ResourceLoaderModule( array(
 316+ 'mediawiki.legacy.metadata' => new ResourceLoaderFileModule( array(
317317 'scripts' => 'skins/common/metadata.js',
318318 'dependencies' => 'mediawiki',
319319 ) ),
320 - 'mediawiki.legacy.mwsuggest' => new ResourceLoaderModule( array(
 320+ 'mediawiki.legacy.mwsuggest' => new ResourceLoaderFileModule( array(
321321 'scripts' => 'skins/common/mwsuggest.js',
322322 'dependencies' => 'mediawiki',
323323 ) ),
324 - 'mediawiki.legacy.password' => new ResourceLoaderModule( array(
 324+ 'mediawiki.legacy.password' => new ResourceLoaderFileModule( array(
325325 'scripts' => 'skins/common/password.js',
326326 'styles' => 'skins/common/password.css',
327327 'dependencies' => 'mediawiki',
328328 ) ),
329 - 'mediawiki.legacy.prefs' => new ResourceLoaderModule( array(
 329+ 'mediawiki.legacy.prefs' => new ResourceLoaderFileModule( array(
330330 'scripts' => 'skins/common/prefs.js',
331331 'dependencies' => 'mediawiki',
332332 ) ),
333 - 'mediawiki.legacy.preview' => new ResourceLoaderModule( array(
 333+ 'mediawiki.legacy.preview' => new ResourceLoaderFileModule( array(
334334 'scripts' => 'skins/common/preview.js',
335335 'dependencies' => 'mediawiki',
336336 ) ),
337 - 'mediawiki.legacy.protect' => new ResourceLoaderModule( array(
 337+ 'mediawiki.legacy.protect' => new ResourceLoaderFileModule( array(
338338 'scripts' => 'skins/common/protect.js',
339339 'dependencies' => 'mediawiki',
340340 ) ),
341 - 'mediawiki.legacy.rightclickedit' => new ResourceLoaderModule( array(
 341+ 'mediawiki.legacy.rightclickedit' => new ResourceLoaderFileModule( array(
342342 'scripts' => 'skins/common/rightclickedit.js',
343343 'dependencies' => 'mediawiki',
344344 ) ),
345 - 'mediawiki.legacy.search' => new ResourceLoaderModule( array(
 345+ 'mediawiki.legacy.search' => new ResourceLoaderFileModule( array(
346346 'scripts' => 'skins/common/search.js',
347347 'dependencies' => 'mediawiki',
348348 ) ),
349 - 'mediawiki.legacy.upload' => new ResourceLoaderModule( array(
 349+ 'mediawiki.legacy.upload' => new ResourceLoaderFileModule( array(
350350 'scripts' => 'skins/common/upload.js',
351351 'dependencies' => 'mediawiki',
352352 ) ),
353 - 'mediawiki.legacy.wikibits' => new ResourceLoaderModule( array(
 353+ 'mediawiki.legacy.wikibits' => new ResourceLoaderFileModule( array(
354354 'scripts' => 'skins/common/wikibits.js',
355355 'dependencies' => 'mediawiki',
356356 'messages' => array( 'showtoc', 'hidetoc' ),

Status & tagging log