r23555 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r23554‎ | r23555 | r23556 >
Date:13:57, 29 June 2007
Author:robchurch
Status:old
Tags:
Comment:
Update for r23553, r23554
Modified paths:
  • /trunk/extensions/SyntaxHighlight_GeSHi/SyntaxHighlight_GeSHi.class.php (modified) (history)
  • /trunk/extensions/SyntaxHighlight_GeSHi/SyntaxHighlight_GeSHi.php (modified) (history)

Diff [purge]

Index: trunk/extensions/SyntaxHighlight_GeSHi/SyntaxHighlight_GeSHi.php
@@ -49,7 +49,7 @@
5050 );
5151
5252 $wgAutoloadClasses['SyntaxHighlight_GeSHi'] = dirname( __FILE__ ) . '/SyntaxHighlight_GeSHi.class.php';
53 -$wgHooks['ShowRawCssJs'][] = 'SyntaxHighlight_GeSHi::viewHook';//array( 'SyntaxHighlight_GeSHi', 'viewHook' );
 53+$wgHooks['ShowRawCssJs'][] = 'SyntaxHighlight_GeSHi::viewHook';
5454 $wgExtensionFunctions[] = 'efSyntaxHighlight_GeSHiSetup';
5555
5656 /**
Index: trunk/extensions/SyntaxHighlight_GeSHi/SyntaxHighlight_GeSHi.class.php
@@ -77,7 +77,7 @@
7878 * @param OutputPage $output
7979 * @return bool
8080 */
81 - public static function viewHook( &$text, $title, $output ) {
 81+ public static function viewHook( $text, $title, $output ) {
8282 // Determine the language
8383 preg_match( '!\.(css|js)$!u', $title->getText(), $matches );
8484 $lang = $matches[1] == 'css' ? 'css' : 'javascript';
@@ -88,7 +88,7 @@
8989 if( !$geshi->error() ) {
9090 // Done
9191 $output->addHeadItem( "source-$lang", self::buildHeadItem( $geshi ) );
92 - $text = $out;
 92+ $output->addHtml( "<div dir=\"ltr\">{$out}</div>" );
9393 return false;
9494 }
9595 }

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r23553Hook callbacks for 'ShowRawCssJs' should do their own output, if so desired; ...robchurch13:52, 29 June 2007
r23554Fix r23553robchurch13:53, 29 June 2007

Status & tagging log