* mediaWiki.confirmCloseWindow now returns an object of functions, instead of
one function. The callback can't be called directly any more. The callback
function is replaced with confirmCloseWindow.release().
+* BREAKING CHANGE: Added an optional ResouceLoaderContext parameter to
+ ResourceLoaderModule::getDependencies(). Extension classes that override that
+ method should be updated. If they aren't updated, PHP Strict standards
+ warnings will appear when E_STRICT error reporting is enabled. Note: in the
+ near future, this parameter will probably become non-optional.
* Removed maintenance script deleteImageMemcached.php.
* MWFunction::newObj() was removed (deprecated in 1.25).
ObjectFactory::getObjectFromSpec() should be used instead.
/**
* Gets list of names of modules this module depends on.
- *
+ * @param ResourceLoaderContext context
* @return array List of module names
*/
- public function getDependencies() {
+ public function getDependencies( ResourceLoaderContext $context = null ) {
return $this->dependencies;
}
}
/**
+ * @param ResourceLoaderContext $context
* @return array
*/
- public function getDependencies() {
+ public function getDependencies( ResourceLoaderContext $context = null ) {
return array( 'mediawiki.language.init' );
}
}
);
}
- public function getDependencies() {
+ /**
+ * @param ResourceLoaderContext $context
+ * @return array
+ */
+ public function getDependencies( ResourceLoaderContext $context = null ) {
return array( 'mediawiki.language.init' );
}
*
* To add dependencies dynamically on the client side, use a custom
* loader script, see getLoaderScript()
+ *
+ * Note: It is expected that $context will be made non-optional in the near
+ * future.
+ *
+ * @param ResourceLoaderContext $context
* @return array List of module names as strings
*/
- public function getDependencies() {
+ public function getDependencies( ResourceLoaderContext $context = null ) {
// Stub, override expected
return array();
}
}
/**
+ * @param ResourceLoaderContext $context
* @return array
*/
- public function getDependencies() {
+ public function getDependencies( ResourceLoaderContext $context = null ) {
return array( 'mediawiki.language' );
}
$registryData[$name] = array(
'version' => $versionHash,
- 'dependencies' => $module->getDependencies(),
+ 'dependencies' => $module->getDependencies( $context ),
'group' => $module->getGroup(),
'source' => $module->getSource(),
'loader' => $module->getLoaderScript(),
protected $targets = array( 'desktop', 'mobile' );
/**
+ * @param ResourceLoaderContext $context
* @return array List of module names as strings
*/
- public function getDependencies() {
+ public function getDependencies( ResourceLoaderContext $context = null ) {
return array( 'user.defaults' );
}
return array( '' => $this->styles );
}
- public function getDependencies() {
+ public function getDependencies( ResourceLoaderContext $context = null ) {
return $this->dependencies;
}