(bug 15925) Properly bold rc bytes changed in all cases. Patch by Happy-melon.
authorChad Horohoe <demon@users.mediawiki.org>
Tue, 14 Oct 2008 12:56:25 +0000 (12:56 +0000)
committerChad Horohoe <demon@users.mediawiki.org>
Tue, 14 Oct 2008 12:56:25 +0000 (12:56 +0000)
CREDITS
RELEASE-NOTES
includes/RecentChange.php

diff --git a/CREDITS b/CREDITS
index c91eb79..66e3f79 100644 (file)
--- a/CREDITS
+++ b/CREDITS
@@ -46,6 +46,7 @@ following names for their contribution to the product.
 * Brad Jorsch
 * Daniel Arnold
 * Danny B.
+* Happy-melon
 * Jeremy Baron
 * Juliano F. Ravasi
 * Louperivois
index bac626d..ff309b5 100644 (file)
@@ -259,6 +259,8 @@ The following extensions are migrated into MediaWiki 1.14:
 * (bug 15846) Categories "leak" from older revisions in certain circumstances
 * (bug 15928) Special pages dropdown should be inline in non-MonoBook skins
 * (bug 14178) Some uses of UserLoadFromSession hook cause segfault 
+* (bug 15925) Postitive bytes added on recentchanges and watchlists are now bolded
+  if above the threshold, previously it only worked for negatives
 
 === API changes in 1.14 ===
 
index 93de943..8f0085a 100644 (file)
@@ -686,14 +686,12 @@ class RecentChange
                $formatedSize = wfMsgExt( 'rc-change-size', array( 'parsemag', 'escape'),
                        $wgLang->formatNum($szdiff) );
 
-               if( $szdiff < $wgRCChangedSizeThreshold ) {
-                       return '<strong class=\'mw-plusminus-neg\'>(' . $formatedSize . ')</strong>';
-               } elseif( $szdiff === 0 ) {
-                       return '<span class=\'mw-plusminus-null\'>(' . $formatedSize . ')</span>';
-               } elseif( $szdiff > 0 ) {
-                       return '<span class=\'mw-plusminus-pos\'>(+' . $formatedSize . ')</span>';
-               } else {
-                       return '<span class=\'mw-plusminus-neg\'>(' . $formatedSize . ')</span>';
-               }
+               return '<'
+               . ( abs($szdiff) > abs($wgRCChangedSizeThreshold) ? 'strong' : 'span' )
+               . ' class="mw-plusminus-'
+               . ( $szdiff == 0 ? 'null' : ( $szdiff > 0 ? 'pos' : 'neg' ))
+               . '/>(' . ( $szdiff > 0 ? '+' : '' )
+               . $formatedSize . ')</span>';
+
        }
 }