Index: trunk/extensions/Maps/includes/Maps_Mapper.php |
— | — | @@ -13,25 +13,6 @@ |
14 | 14 | final class MapsMapper { |
15 | 15 | |
16 | 16 | /** |
17 | | - * Add a JavaScript file out of skins/common, or a given relative path. |
18 | | - * |
19 | | - * This is a copy of the native function in OutputPage to work around a pre MW 1.16 bug. |
20 | | - * Should be used for adding external files, like the Google Maps API. |
21 | | - * |
22 | | - * @param OutputPage $out |
23 | | - * @param string $file |
24 | | - */ |
25 | | - public static function addScriptFile( OutputPage $out, $file ) { |
26 | | - global $wgStylePath, $wgStyleVersion; |
27 | | - if( substr( $file, 0, 1 ) == '/' || preg_match( '#^[a-z]*://#i', $file ) ) { |
28 | | - $path = $file; |
29 | | - } else { |
30 | | - $path = "{$wgStylePath}/common/{$file}"; |
31 | | - } |
32 | | - $out->addScript( Html::linkedScript( wfAppendQuery( $path, $wgStyleVersion ) ) ); |
33 | | - } |
34 | | - |
35 | | - /** |
36 | 17 | * Encode a variable of unknown type to JavaScript. |
37 | 18 | * Arrays are converted to JS arrays, objects are converted to JS associative |
38 | 19 | * arrays (objects). So cast your PHP associative arrays to objects before |