r63384 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r63383‎ | r63384 | r63385 >
Date:12:09, 8 March 2010
Author:aaron
Status:ok
Tags:
Comment:
ReviewedPages UI cleanup
Modified paths:
  • /trunk/extensions/FlaggedRevs/language/ReviewedPages.i18n.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/specialpages/ReviewedPages_body.php (modified) (history)

Diff [purge]

Index: trunk/extensions/FlaggedRevs/language/ReviewedPages.i18n.php
@@ -9,14 +9,15 @@
1010
1111 $messages['en'] = array(
1212 'reviewedpages' => 'Reviewed pages',
13 - 'reviewedpages-leg' => 'List pages by highest review level',
14 - 'reviewedpages-list' => 'This page lists pages that been reviewed (at highest) to the specified level.',
 13+ 'reviewedpages-leg' => 'List pages that have been reviewed',
 14+ 'reviewedpages-list' => 'This lists contains [[{{MediaWiki:Validationpage}}|reviewed]] pages whose \'\'highest attained\'\' review level (of a revision) is the specified level.
 15+ A link is given to the latest revision of that level.',
1516 'reviewedpages-none' => 'There are no pages in this list',
1617 'reviewedpages-lev-0' => '{{int:revreview-lev-basic}}',
1718 'reviewedpages-lev-1' => '{{int:revreview-lev-quality}}',
1819 'reviewedpages-lev-2' => '{{int:revreview-lev-pristine}}',
1920 'reviewedpages-all' => 'reviewed versions',
20 - 'reviewedpages-best' => 'prime revision',
 21+ 'reviewedpages-best' => 'best revision',
2122 );
2223
2324 /** Message documentation (Message documentation)
Index: trunk/extensions/FlaggedRevs/specialpages/ReviewedPages_body.php
@@ -69,7 +69,10 @@
7070 $this->namespace, $this->hideRedirs );
7171 $num = $pager->getNumRows();
7272 if ( $num ) {
73 - $wgOut->addHTML( wfMsgExt( 'reviewedpages-list', array( 'parse' ), $num ) );
 73+ // Text to explain level select (if there are several levels)
 74+ if ( FlaggedRevs::qualityVersions() ) {
 75+ $wgOut->addHTML( wfMsgExt( 'reviewedpages-list', array( 'parse' ), $num ) );
 76+ }
7477 $wgOut->addHTML( $pager->getNavigationBar() );
7578 $wgOut->addHTML( $pager->getBody() );
7679 $wgOut->addHTML( $pager->getNavigationBar() );
@@ -93,13 +96,23 @@
9497 $wgLang->formatNum( $size ) ) . '</small>';
9598 }
9699
97 - $SVtitle = SpecialPage::getTitleFor( 'ReviewedVersions' );
98 - $list = $this->skin->makeKnownLinkObj( $SVtitle, wfMsgHtml( 'reviewedpages-all' ),
99 - 'page=' . $title->getPrefixedUrl() );
100 - $best = $this->skin->makeKnownLinkObj( $title, wfMsgHtml( 'reviewedpages-best' ),
101 - 'stableid=best' );
 100+ $list = $this->skin->makeKnownLinkObj(
 101+ SpecialPage::getTitleFor( 'ReviewedVersions' ),
 102+ wfMsgHtml( 'reviewedpages-all' ),
 103+ 'page=' . $title->getPrefixedUrl()
 104+ );
102105
103 - return "<li>$link $stxt ($list) [$best]</li>";
 106+ $best = '';
 107+ if ( FlaggedRevs::qualityVersions() ) {
 108+ $best = $this->skin->makeKnownLinkObj(
 109+ $title,
 110+ wfMsgHtml( 'reviewedpages-best' ),
 111+ 'stableid=best'
 112+ );
 113+ $best = " [$best]";
 114+ }
 115+
 116+ return "<li>$link $stxt ($list)$best</li>";
104117 }
105118 }
106119

Status & tagging log