Index: trunk/extensions/CodeReview/SpecialCode.php |
— | — | @@ -7,17 +7,12 @@ |
8 | 8 | } |
9 | 9 | |
10 | 10 | function execute( $subpage ) { |
11 | | - global $wgOut, $wgRequest, $wgUser, $wgScriptPath; |
| 11 | + global $wgOut, $wgRequest, $wgUser, $wgScriptPath, $wgCodeReviewStyleVersion; |
12 | 12 | |
13 | 13 | wfLoadExtensionMessages( 'CodeReview' ); |
14 | 14 | |
15 | 15 | $this->setHeaders(); |
16 | | - global $wgCodeReviewStylePath, $wgCodeReviewStyleVersion; |
17 | | - $stylePath = str_replace( '$wgScriptPath', $wgScriptPath, $wgCodeReviewStylePath ); |
18 | | - $encCssFile = htmlspecialchars( "$stylePath/codereview.css?$wgCodeReviewStyleVersion" ); |
19 | | - $encJsFile = htmlspecialchars( "$stylePath/codereview.js?$wgCodeReviewStyleVersion" ); |
20 | | - $wgOut->addExtensionStyle( $encCssFile ); |
21 | | - $wgOut->addScriptFile( "$wgScriptPath/extensions/CodeReview/codereview.js" ); |
| 16 | + $wgOut->addStyle( "$wgScriptPath/extensions/CodeReview/codereview.css?$wgCodeReviewStyleVersion" ); |
22 | 17 | |
23 | 18 | if( $subpage == '' ) { |
24 | 19 | $view = new CodeRepoListView(); |
Index: trunk/extensions/CodeReview/CodeRevisionView.php |
— | — | @@ -296,6 +296,7 @@ |
297 | 297 | global $wgOut, $wgScriptPath; |
298 | 298 | $encRepo = Xml::encodeJsVar( $this->mRepo->getName() ); |
299 | 299 | $encRev = Xml::encodeJsVar( $this->mRev->getId() ); |
| 300 | + $wgOut->addScriptFile( "$wgScriptPath/extensions/CodeReview/codereview.js" ); |
300 | 301 | $wgOut->addInlineScript( |
301 | 302 | "addOnloadHook( |
302 | 303 | function() { |
Index: trunk/extensions/CodeReview/CodeReview.php |
— | — | @@ -96,8 +96,6 @@ |
97 | 97 | $wgSubversionProxy = false; |
98 | 98 | $wgSubversionProxyTimeout = 30; // default 3 secs is too short :) |
99 | 99 | |
100 | | -# Use a literal $wgScriptPath as a placeholder for the runtime value of $wgScriptPath |
101 | | -$wgCodeReviewStylePath = '$wgScriptPath/extensions/CodeReview'; |
102 | 100 | |
103 | 101 | $wgCodeReviewStyleVersion = 3; |
104 | 102 | // The name of a repo which represents the code running on this wiki, used to highlight active revisions |