r81811 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r81810‎ | r81811 | r81812 >
Date:08:59, 9 February 2011
Author:aaron
Status:ok
Tags:
Comment:
Replaced ugly "array( 'parseinline' )" param with shorter "'parseline'" param
Modified paths:
  • /trunk/extensions/FlaggedRevs/FlaggedArticleView.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/FlaggedRevsXML.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/specialpages/Stabilization_body.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/specialpages/ValidationStatistics_body.php (modified) (history)

Diff [purge]

Index: trunk/extensions/FlaggedRevs/specialpages/Stabilization_body.php
@@ -193,12 +193,12 @@
194194 </tr>';
195195 # Add comment input and submit button
196196 if ( $form->isAllowed() ) {
197 - $watchLabel = wfMsgExt( 'watchthis', array( 'parseinline' ) );
 197+ $watchLabel = wfMsgExt( 'watchthis', 'parseinline' );
198198 $watchAttribs = array( 'accesskey' => wfMsg( 'accesskey-watch' ),
199199 'id' => 'wpWatchthis' );
200200 $watchChecked = ( $wgUser->getOption( 'watchdefault' )
201201 || $title->userIsWatching() );
202 - $reviewLabel = wfMsgExt( 'stabilization-review', array( 'parseinline' ) );
 202+ $reviewLabel = wfMsgExt( 'stabilization-review', 'parseinline' );
203203
204204 $s .= ' <tr>
205205 <td class="mw-label">' .
Index: trunk/extensions/FlaggedRevs/specialpages/ValidationStatistics_body.php
@@ -82,7 +82,7 @@
8383 $msgs = array( 'ns', 'total', 'stable', 'latest', 'synced', 'old' ); // our headings
8484 foreach ( $msgs as $msg ) {
8585 $wgOut->addHTML( '<th>' .
86 - wfMsgExt( "validationstatistics-$msg", array( 'parseinline' ) ) . '</th>' );
 86+ wfMsgExt( "validationstatistics-$msg", 'parseinline' ) . '</th>' );
8787 }
8888 $wgOut->addHTML( "</tr>\n" );
8989 $namespaces = FlaggedRevs::getReviewNamespaces();
Index: trunk/extensions/FlaggedRevs/FlaggedRevsXML.php
@@ -237,12 +237,12 @@
238238 if ( $synced && ( $type == 'stable' || $type == 'draft' ) ) {
239239 $msg = $quality ?
240240 'revreview-quality-same' : 'revreview-basic-same';
241 - $html = wfMsgExt( $msg, array( 'parseinline' ),
 241+ $html = wfMsgExt( $msg, 'parseinline',
242242 $frev->getRevId(), $time, $revsSince );
243243 } elseif ( $type == 'oldstable' ) {
244244 $msg = $quality ?
245245 'revreview-quality-old' : 'revreview-basic-old';
246 - $html = wfMsgExt( $msg, array( 'parseinline' ), $frev->getRevId(), $time );
 246+ $html = wfMsgExt( $msg, 'parseinline', $frev->getRevId(), $time );
247247 } else {
248248 if ( $type == 'stable' ) {
249249 $msg = $quality ?
@@ -254,7 +254,7 @@
255255 # For searching: uses messages 'revreview-quality-i', 'revreview-basic-i',
256256 # 'revreview-newest-quality-i', 'revreview-newest-basic-i'
257257 $msg .= ( $revsSince == 0 ) ? '-i' : '';
258 - $html = wfMsgExt( $msg, array( 'parseinline' ),
 258+ $html = wfMsgExt( $msg, 'parseinline',
259259 $frev->getRevId(), $time, $revsSince );
260260 }
261261 # Make fancy box...
@@ -404,7 +404,7 @@
405405 $msg = FlaggedRevs::isQuality( $flags )
406406 ? 'revreview-pending-quality'
407407 : 'revreview-pending-basic';
408 - $tag = wfMsgExt( $msg, array( 'parseinline' ), $frev->getRevId(), $time, $revsSince );
 408+ $tag = wfMsgExt( $msg, 'parseinline', $frev->getRevId(), $time, $revsSince );
409409 return $tag;
410410 }
411411
Index: trunk/extensions/FlaggedRevs/FlaggedArticleView.php
@@ -242,7 +242,7 @@
243243 $flags = $frev->getTags();
244244 $quality = FlaggedRevs::isQuality( $flags );
245245 $msg = $quality ? 'revreview-quality-source' : 'revreview-basic-source';
246 - $tag = wfMsgExt( $msg, array( 'parseinline' ), $frev->getRevId(), $time );
 246+ $tag = wfMsgExt( $msg, 'parseinline', $frev->getRevId(), $time );
247247 # Hide clutter
248248 if ( !$this->useSimpleUI() && !empty( $flags ) ) {
249249 $tag .= FlaggedRevsXML::ratingToggle() .
@@ -403,14 +403,14 @@
404404 if ( $this->useSimpleUI() ) {
405405 // RTL langauges
406406 $rtl = $wgContLang->isRTL() ? " rtl" : "";
407 - $tag .= $prot . $icon . wfMsgExt( 'revreview-quick-none', array( 'parseinline' ) );
 407+ $tag .= $prot . $icon . wfMsgExt( 'revreview-quick-none', 'parseinline' );
408408 $css = "flaggedrevs_short{$rtl} plainlinks noprint";
409409 $this->reviewNotice .= "<div id='mw-fr-revisiontag' class='$css'>$tag</div>";
410410 // Standard UI
411411 } else {
412412 $css = 'flaggedrevs_notice plainlinks noprint';
413413 $tag = "<div id='mw-fr-revisiontag' class='$css'>" .
414 - $prot . $icon . wfMsgExt( 'revreview-noflagged', array( 'parseinline' ) ) .
 414+ $prot . $icon . wfMsgExt( 'revreview-noflagged', 'parseinline' ) .
415415 "</div>";
416416 $this->reviewNotice .= $tag;
417417 }
@@ -454,7 +454,7 @@
455455 $pending .= FlaggedRevsXML::draftStatusIcon();
456456 }
457457 $pending .= wfMsgExt( 'revreview-edited',
458 - array( 'parseinline' ), $srev->getRevId(), $revsSince );
 458+ 'parseinline', $srev->getRevId(), $revsSince );
459459 $anchor = $wgRequest->getVal( 'fromsection' );
460460 if ( $anchor != null ) {
461461 $section = str_replace( '_', ' ', $anchor ); // prettify
@@ -476,13 +476,13 @@
477477 $msg = $quality
478478 ? 'revreview-quick-quality-same'
479479 : 'revreview-quick-basic-same';
480 - $msgHTML = wfMsgExt( $msg, array( 'parseinline' ),
 480+ $msgHTML = wfMsgExt( $msg, 'parseinline',
481481 $srev->getRevId(), $revsSince );
482482 } else {
483483 $msg = $quality
484484 ? 'revreview-quick-see-quality'
485485 : 'revreview-quick-see-basic';
486 - $msgHTML = wfMsgExt( $msg, array( 'parseinline' ),
 486+ $msgHTML = wfMsgExt( $msg, 'parseinline',
487487 $srev->getRevId(), $revsSince );
488488 }
489489 $icon = '';
@@ -503,14 +503,14 @@
504504 } else {
505505 $msg = 'revreview-basic-same';
506506 }
507 - $msgHTML = wfMsgExt( $msg, array( 'parseinline' ),
 507+ $msgHTML = wfMsgExt( $msg, 'parseinline',
508508 $srev->getRevId(), $time, $revsSince );
509509 } else {
510510 $msg = $quality
511511 ? 'revreview-newest-quality'
512512 : 'revreview-newest-basic';
513513 $msg .= ( $revsSince == 0 ) ? '-i' : '';
514 - $msgHTML = wfMsgExt( $msg, array( 'parseinline' ),
 514+ $msgHTML = wfMsgExt( $msg, 'parseinline',
515515 $srev->getRevId(), $time, $revsSince );
516516 }
517517 $icon = $synced
@@ -558,7 +558,7 @@
559559 $msg = $quality
560560 ? 'revreview-quick-quality-old'
561561 : 'revreview-quick-basic-old';
562 - $msgHTML = wfMsgExt( $msg, array( 'parseinline' ), $frev->getRevId(), $revsSince );
 562+ $msgHTML = wfMsgExt( $msg, 'parseinline', $frev->getRevId(), $revsSince );
563563 }
564564 $msgHTML = $prot . $icon . $msgHTML;
565565 $tag = FlaggedRevsXML::prettyRatingBox( $frev, $msgHTML,
@@ -634,7 +634,7 @@
635635 : 'revreview-quick-basic';
636636 # Uses messages 'revreview-quick-quality-same', 'revreview-quick-basic-same'
637637 $msg = $synced ? "{$msg}-same" : $msg;
638 - $msgHTML = wfMsgExt( $msg, array( 'parseinline' ),
 638+ $msgHTML = wfMsgExt( $msg, 'parseinline',
639639 $srev->getRevId(), $revsSince );
640640 }
641641 $msgHTML = $prot . $icon . $msgHTML;
@@ -916,7 +916,7 @@
917917 # Let new users know about review procedure a tag.
918918 # If the log excerpt was shown this is redundant.
919919 if ( !$log && !$wgUser->getId() && $this->article->isStableShownByDefault() ) {
920 - $items[] = wfMsgExt( 'revreview-editnotice', array( 'parseinline' ) );
 920+ $items[] = wfMsgExt( 'revreview-editnotice', 'parseinline' );
921921 }
922922 # Add a notice if there are pending edits...
923923 if ( $this->article->revsArePending() ) {
@@ -1002,7 +1002,7 @@
10031003 $revsSince = $this->article->getPendingRevCount();
10041004 if ( $revsSince ) {
10051005 $s .= "<div class='flaggedrevs_editnotice plainlinks'>" .
1006 - wfMsgExt( 'revreview-pending-nosection', array( 'parseinline' ),
 1006+ wfMsgExt( 'revreview-pending-nosection', 'parseinline',
10071007 $srev->getRevId(), $revsSince ) . "</div>";
10081008 }
10091009 }
@@ -1109,15 +1109,15 @@
11101110 $frev = $this->article->getStableRev();
11111111 if ( $frev && $frev->getRevId() == $this->article->getLatest() ) {
11121112 $wgOut->prependHTML( "<span class='plainlinks'>" .
1113 - wfMsgExt( 'revreview-visibility', array( 'parseinline' ),
 1113+ wfMsgExt( 'revreview-visibility', 'parseinline',
11141114 $title->getPrefixedText() ) . "</span>" );
11151115 } elseif ( $frev ) {
11161116 $wgOut->prependHTML( "<span class='plainlinks'>" .
1117 - wfMsgExt( 'revreview-visibility2', array( 'parseinline' ),
 1117+ wfMsgExt( 'revreview-visibility2', 'parseinline',
11181118 $title->getPrefixedText() ) . "</span>" );
11191119 } else {
11201120 $wgOut->prependHTML( "<span class='plainlinks'>" .
1121 - wfMsgExt( 'revreview-visibility3', array( 'parseinline' ),
 1121+ wfMsgExt( 'revreview-visibility3', 'parseinline',
11221122 $title->getPrefixedText() ) . "</span>" );
11231123 }
11241124 }

Status & tagging log