Revision: 46205
Author: ialex
Date: 2009-01-25 16:34:21 +0000 (Sun, 25 Jan 2009)
Log Message:
-----------
* fix usage of 'number_of_watching_users_RCview' message to correspond with the
other one in the same file
* use $this->message['hist'] rather than wfMsg( 'hist' )
* Whitespaces tweaks
Modified Paths:
--------------
trunk/phase3/includes/ChangesList.php
Modified: trunk/phase3/includes/ChangesList.php
===================================================================
--- trunk/phase3/includes/ChangesList.php 2009-01-25 15:53:17 UTC (rev
46204)
+++ trunk/phase3/includes/ChangesList.php 2009-01-25 16:34:21 UTC (rev
46205)
@@ -108,7 +108,7 @@
public static function showCharacterDifference( $old, $new ) {
global $wgRCChangedSizeThreshold, $wgLang;
$szdiff = $new - $old;
- $formatedSize = wfMsgExt( 'rc-change-size', array( 'parsemag',
'escape'), $wgLang->formatNum($szdiff) );
+ $formatedSize = wfMsgExt( 'rc-change-size', array( 'parsemag',
'escape' ), $wgLang->formatNum( $szdiff ) );
if( abs( $szdiff ) > abs( $wgRCChangedSizeThreshold ) ) {
$tag = 'strong';
} else {
@@ -223,9 +223,9 @@
}
/** Insert links to user page, user talk page and eventually a blocking
link */
- public function insertUserRelatedLinks(&$s, &$rc) {
- if( $this->isDeleted($rc,Revision::DELETED_USER) ) {
- $s .= ' <span class="history-deleted">' .
wfMsgHtml('rev-deleted-user') . '</span>';
+ public function insertUserRelatedLinks( &$s, &$rc ) {
+ if( $this->isDeleted( $rc, Revision::DELETED_USER ) ) {
+ $s .= ' <span class="history-deleted">' . wfMsgHtml(
'rev-deleted-user' ) . '</span>';
} else {
$s .= $this->skin->userLink( $rc->mAttribs['rc_user'],
$rc->mAttribs['rc_user_text'] );
$s .= $this->skin->userToolLinks( $rc->mAttribs['rc_user'],
$rc->mAttribs['rc_user_text'] );
@@ -233,22 +233,22 @@
}
/** insert a formatted action */
- protected function insertAction(&$s, &$rc) {
+ protected function insertAction( &$s, &$rc ) {
if( $rc->mAttribs['rc_type'] == RC_LOG ) {
- if( $this->isDeleted($rc,LogPage::DELETED_ACTION) ) {
- $s .= ' <span class="history-deleted">' .
wfMsgHtml('rev-deleted-event') . '</span>';
+ if( $this->isDeleted( $rc, LogPage::DELETED_ACTION ) ) {
+ $s .= ' <span class="history-deleted">' .
wfMsgHtml( 'rev-deleted-event' ) . '</span>';
} else {
$s .= ' '.LogPage::actionText(
$rc->mAttribs['rc_log_type'], $rc->mAttribs['rc_log_action'],
- $rc->getTitle(), $this->skin,
LogPage::extractParams($rc->mAttribs['rc_params']), true, true );
+ $rc->getTitle(), $this->skin,
LogPage::extractParams( $rc->mAttribs['rc_params'] ), true, true );
}
}
}
/** insert a formatted comment */
- protected function insertComment(&$s, &$rc) {
+ protected function insertComment( &$s, &$rc ) {
if( $rc->mAttribs['rc_type'] != RC_MOVE &&
$rc->mAttribs['rc_type'] != RC_MOVE_OVER_REDIRECT ) {
- if( $this->isDeleted($rc,Revision::DELETED_COMMENT) ) {
- $s .= ' <span class="history-deleted">' .
wfMsgHtml('rev-deleted-comment') . '</span>';
+ if( $this->isDeleted( $rc, Revision::DELETED_COMMENT )
) {
+ $s .= ' <span class="history-deleted">' .
wfMsgHtml( 'rev-deleted-comment' ) . '</span>';
} else {
$s .= $this->skin->commentBlock(
$rc->mAttribs['rc_comment'], $rc->getTitle() );
}
@@ -272,8 +272,8 @@
static $cache = array();
if( $count > 0 ) {
if( !isset( $cache[$count] ) ) {
- $cache[$count] =
wfMsgExt('number_of_watching_users_RCview',
- array('parsemag', 'escape'),
$wgLang->formatNum($count));
+ $cache[$count] = wfMsgExt(
'number_of_watching_users_RCview',
+ array('parsemag', 'escape' ),
$wgLang->formatNum( $count ) );
}
return $cache[$count];
} else {
@@ -288,7 +288,7 @@
* @return bool
*/
public static function isDeleted( $rc, $field ) {
- return ($rc->mAttribs['rc_deleted'] & $field) == $field;
+ return ( $rc->mAttribs['rc_deleted'] & $field ) == $field;
}
/**
@@ -349,7 +349,7 @@
* Format a line using the old system (aka without any javascript).
*/
public function recentChangesLine( &$rc, $watched = false ) {
- global $wgContLang, $wgRCShowChangedSize, $wgUser;
+ global $wgContLang, $wgLang, $wgRCShowChangedSize, $wgUser;
wfProfileIn( __METHOD__ );
# Should patrol-related stuff be shown?
$unpatrolled = $wgUser->useRCPatrol() &&
!$rc->mAttribs['rc_patrolled'];
@@ -402,8 +402,8 @@
}
# How many users watch this page
if( $rc->numberofWatchingusers > 0 ) {
- $s .= ' ' . wfMsg( 'number_of_watching_users_RCview',
-
$wgContLang->formatNum($rc->numberofWatchingusers) );
+ $s .= ' ' . wfMsgExt(
'number_of_watching_users_RCview',
+ array( 'parsemag', 'escape' ),
$wgLang->formatNum( $rc->numberofWatchingusers ) );
}
wfRunHooks( 'OldChangesListRecentChangesLine', array(&$this,
&$s, $rc) );
@@ -550,7 +550,7 @@
# Make user links
if( $this->isDeleted($rc,Revision::DELETED_USER) ) {
- $rc->userlink = ' <span class="history-deleted">' .
wfMsgHtml('rev-deleted-user') . '</span>';
+ $rc->userlink = ' <span class="history-deleted">' .
wfMsgHtml( 'rev-deleted-user' ) . '</span>';
} else {
$rc->userlink = $this->skin->userLink( $rc_user,
$rc_user_text );
$rc->usertalklink = $this->skin->userToolLinks(
$rc_user, $rc_user_text );
@@ -650,8 +650,8 @@
# onclick handler to toggle hidden/expanded
$toggleLink = "onclick='toggleVisibility($jsid); return false'";
# Title for <a> tags
- $expandTitle = htmlspecialchars( wfMsg('rc-enhanced-expand') );
- $closeTitle = htmlspecialchars( wfMsg('rc-enhanced-hide') );
+ $expandTitle = htmlspecialchars( wfMsg( 'rc-enhanced-expand' )
);
+ $closeTitle = htmlspecialchars( wfMsg( 'rc-enhanced-hide' ) );
$tl = "<span id='mw-rc-openarrow-$jsid'
class='mw-changeslist-expanded' style='visibility:hidden'><a href='#'
$toggleLink title='$expandTitle'>" . $this->sideArrow() . "</a></span>";
$tl .= "<span id='mw-rc-closearrow-$jsid'
class='mw-changeslist-hidden' style='display:none'><a href='#' $toggleLink
title='$closeTitle'>" . $this->downArrow() . "</a></span>";
@@ -665,7 +665,7 @@
# Article link
if( $namehidden ) {
- $r .= ' <span class="history-deleted">' .
wfMsgHtml('rev-deleted-event') . '</span>';
+ $r .= ' <span class="history-deleted">' . wfMsgHtml(
'rev-deleted-event' ) . '</span>';
} else if( $allLogs ) {
$r .= $this->maybeWatchedLink( $block[0]->link,
$block[0]->watched );
} else {
@@ -685,7 +685,7 @@
$r .= ' ';
if( !$allLogs ) {
$r .= '(';
- if(
!ChangesList::userCan($rcObj,Revision::DELETED_TEXT) ) {
+ if( !ChangesList::userCan( $rcObj,
Revision::DELETED_TEXT ) ) {
$r .= $nchanges[$n];
} else if( $isnew ) {
$r .= $nchanges[$n];
@@ -826,7 +826,7 @@
protected function sideArrow() {
global $wgContLang;
$dir = $wgContLang->isRTL() ? 'l' : 'r';
- return $this->arrow( $dir, '+', wfMsg('rc-enhanced-expand') );
+ return $this->arrow( $dir, '+', wfMsg( 'rc-enhanced-expand' ) );
}
/**
@@ -835,7 +835,7 @@
* @return string HTML <img> tag
*/
protected function downArrow() {
- return $this->arrow( 'd', '-', wfMsg('rc-enhanced-hide') );
+ return $this->arrow( 'd', '-', wfMsg( 'rc-enhanced-hide' ) );
}
/**
@@ -886,7 +886,7 @@
# Diff and hist links
if ( $rc_type != RC_LOG ) {
$r .= ' ('. $rcObj->difflink .
$this->message['semicolon-separator'];
- $r .= $this->skin->makeKnownLinkObj(
$rcObj->getTitle(), wfMsg( 'hist' ),
+ $r .= $this->skin->makeKnownLinkObj(
$rcObj->getTitle(), $this->message['hist'],
$curIdEq.'&action=history' ) . ')';
}
$r .= ' . . ';
_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs