From e7ddfcf22e750fc41c4cf72f5604f4b1b5d97908 Mon Sep 17 00:00:00 2001 From: Liangent Date: Tue, 29 May 2012 16:28:07 +0800 Subject: [PATCH] replace whitespace with 'word-separator' message Change-Id: I34e099af74196579f20685e45d81b00ed8f76461 --- includes/ImagePage.php | 7 +++++-- includes/Linker.php | 10 +++++++--- includes/Preferences.php | 5 ++++- 3 files changed, 16 insertions(+), 6 deletions(-) diff --git a/includes/ImagePage.php b/includes/ImagePage.php index b1a505758a..8f683e9207 100644 --- a/includes/ImagePage.php +++ b/includes/ImagePage.php @@ -1114,8 +1114,11 @@ class ImageHistoryList extends ContextSource { $row .= '' . wfMsgHtml( 'rev-deleted-user' ) . ''; } else { if ( $local ) { - $row .= Linker::userLink( $userId, $userText ) . ' ' . - Linker::userToolLinks( $userId, $userText ) . ''; + $row .= Linker::userLink( $userId, $userText ); + $row .= $this->getContext()->msg( 'word-separator' )->plain(); + $row .= ''; + $row .= Linker::userToolLinks( $userId, $userText ); + $row .= ''; } else { $row .= htmlspecialchars( $userText ); } diff --git a/includes/Linker.php b/includes/Linker.php index 722df3ae1d..35b6a8f0a5 100644 --- a/includes/Linker.php +++ b/includes/Linker.php @@ -1041,7 +1041,10 @@ class Linker { wfRunHooks( 'UserToolLinksEdit', array( $userId, $userText, &$items ) ); if ( $items ) { - return ' ' . wfMessage( 'parentheses' )->rawParams( $wgLang->pipeList( $items ) )->escaped() . ''; + return wfMessage( 'word-separator' )->plain() + . '' + . wfMessage( 'parentheses' )->rawParams( $wgLang->pipeList( $items ) )->escaped() + . ''; } else { return ''; } @@ -1125,8 +1128,9 @@ class Linker { } elseif ( $rev->userCan( Revision::DELETED_USER ) ) { $userId = $rev->getUser( Revision::FOR_THIS_USER ); $userText = $rev->getUserText( Revision::FOR_THIS_USER ); - $link = self::userLink( $userId, $userText ) . - ' ' . self::userToolLinks( $userId, $userText ); + $link = self::userLink( $userId, $userText ) + . wfMessage( 'word-separator' )->plain() + . self::userToolLinks( $userId, $userText ); } else { $link = wfMsgHtml( 'rev-deleted-user' ); } diff --git a/includes/Preferences.php b/includes/Preferences.php index 3eee19101d..bf63d652d4 100644 --- a/includes/Preferences.php +++ b/includes/Preferences.php @@ -371,7 +371,10 @@ class Preferences { $emailAddress = $user->getEmail() ? htmlspecialchars( $user->getEmail() ) : ''; if ( $wgAuth->allowPropChange( 'emailaddress' ) ) { - $emailAddress .= $emailAddress == '' ? $link : ( ' ' . $context->msg( 'parentheses' )->rawParams( $link )->plain() ); + $emailAddress .= $emailAddress == '' ? $link : ( + $context->msg( 'word-separator' )->plain() + . $context->msg( 'parentheses' )->rawParams( $link )->plain() + ); } -- 2.20.1