r40888 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r40887‎ | r40888 | r40889 >
Date:23:15, 15 September 2008
Author:brion
Status:old
Tags:
Comment:
comment permalinks
Modified paths:
  • /trunk/extensions/CodeReview/CodeReview.i18n.php (modified) (history)
  • /trunk/extensions/CodeReview/SpecialCode.php (modified) (history)

Diff [purge]

Index: trunk/extensions/CodeReview/CodeReview.i18n.php
@@ -26,7 +26,7 @@
2727 'code-rev-modified-c' => 'copied',
2828 'code-rev-modified-d' => 'deleted',
2929 'code-rev-modified-m' => 'modified',
30 - 'code-rev-comment-by' => 'Comment by',
 30+ 'code-rev-comment-by' => 'Comment by $1',
3131 'code-rev-comment-submit' => 'Submit comment',
3232 'code-rev-comment-preview' => 'Preview',
3333 'code-rev-diff' => 'Diff',
Index: trunk/extensions/CodeReview/SpecialCode.php
@@ -357,16 +357,23 @@
358358 function formatComment( $comment, $replyForm='' ) {
359359 global $wgOut, $wgLang;
360360 $linker = new CodeCommentLinkerWiki( $this->mRepo );
 361+
 362+ $repo = $this->mRepo->getName();
 363+ $rev = $this->mRev->getId();
 364+ $perma = SpecialPage::getTitleFor( 'Code', "$repo/$rev" );
 365+ $perma->setFragment( "#c{$comment->id}" );
 366+
361367 return Xml::openElement( 'div',
362368 array(
363369 'class' => 'mw-codereview-comment',
364370 'id' => 'c' . intval( $comment->id ),
365371 'style' => $this->commentStyle( $comment ) ) ) .
366372 '<div class="mw-codereview-comment-meta">' .
367 - wfMsgHtml( 'code-rev-comment-by' ) . ' ' .
368 - $this->mSkin->userLink( $comment->user, $comment->userText ) .
369 - $this->mSkin->userToolLinks( $comment->user, $comment->userText ) .
370 - ' ' .
 373+ $this->mSkin->link( $perma, "#" ) .
 374+ wfMsgHtml( 'code-rev-comment-by',
 375+ $this->mSkin->userLink( $comment->user, $comment->userText ) .
 376+ $this->mSkin->userToolLinks( $comment->user, $comment->userText ) ) .
 377+ ' &nbsp; ' .
371378 $wgLang->timeanddate( $comment->timestamp ) .
372379 ' ' .
373380 $this->commentReplyLink( $comment->id ) .

Status & tagging log