* (bug 7519) Add plural in SpecialWatchlist
authorJimmy Collins <collinj@users.mediawiki.org>
Sun, 8 Oct 2006 01:14:16 +0000 (01:14 +0000)
committerJimmy Collins <collinj@users.mediawiki.org>
Sun, 8 Oct 2006 01:14:16 +0000 (01:14 +0000)
RELEASE-NOTES
includes/SpecialWatchlist.php
languages/messages/MessagesDe.php
languages/messages/MessagesEn.php

index e1d0101..5001e13 100644 (file)
@@ -270,6 +270,7 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN
   excessive metadata in thumbs (requires ImageMagick 6.0.0 or newer).
 * (bug 7499) Corrections to Swedish talk namespace names
 * (bug 7508) Added option to compress HTML pages by dumpHTML.php
+* (bug 7519) Add plural in SpecialWatchlist
 
 == Languages updated ==
 
index 3825675..9f709cc 100644 (file)
@@ -273,7 +273,7 @@ function wfSpecialWatchlist( $par ) {
        }
 
        # TODO: Consider removing the third parameter
-       $header .= wfMsg( 'watchdetails', $wgLang->formatNum( $nitems ),
+       $header .= wfMsgExt( 'watchdetails', array( 'parsemag', 'escape'), $wgLang->formatNum( $nitems ),
                $wgLang->formatNum( $npages ), '',
                $specialTitle->getFullUrl( 'edit=yes' ) );
        $wgOut->addWikiText( $header );
@@ -476,6 +476,8 @@ function wlCountItems( &$user, $talk = true ) {
  *                             code needs to do something further
  */
 function wlHandleClear( &$out, &$request, $par ) {
+       global $wgLang;
+
        # Check this function has something to do
        if( $request->getText( 'action' ) == 'clear' || $par == 'clear' ) {
                global $wgUser;
@@ -487,13 +489,13 @@ function wlHandleClear( &$out, &$request, $par ) {
                                # Clearing, so do it and report the result
                                $dbw =& wfGetDB( DB_MASTER );
                                $dbw->delete( 'watchlist', array( 'wl_user' => $wgUser->mId ), 'wlHandleClear' );
-                               $out->addWikiText( wfMsg( 'watchlistcleardone', $count ) );
+                               $out->addWikiText( wfMsgExt( 'watchlistcleardone', array( 'parsemag', 'escape'), $wgLang->formatNum( $count ) ) );
                                $out->returnToMain();
                        } else {
                                # Confirming, so show a form
                                $wlTitle = Title::makeTitle( NS_SPECIAL, 'Watchlist' );
                                $out->addHTML( wfElement( 'form', array( 'method' => 'post', 'action' => $wlTitle->getLocalUrl( 'action=clear' ) ), NULL ) );
-                               $out->addWikiText( wfMsg( 'watchlistcount', $count ) );
+                               $out->addWikiText( wfMsgExt( 'watchlistcount', array( 'parsemag', 'escape'), $wgLang->formatNum( $count ) ) );
                                $out->addWikiText( wfMsg( 'watchlistcleartext' ) );
                                $out->addHTML(
                                        wfHidden( 'token', $wgUser->editToken( 'clearwatchlist' ) ) .
index 2e28b57..dc8d778 100644 (file)
@@ -1018,11 +1018,11 @@ Davon sind \'\'\'$2\'\'\' (=$4%) $5.',
 'watchlistfor'         => '(für \'\'\'$1\'\'\')',
 "nowatchlist"  => "Sie haben keine Einträge auf Ihrer Beobachtungsliste.",
 'watchlistanontext'    => 'Sie müssen sich $1, um Ihre Beobachtungsliste zu sehen oder Einträge auf ihr zu bearbeiten.',     // $1 -> 'loginreqlink'
-'watchlistcount'       => '\'\'\'Sie haben $1 Einträge auf Ihrer Beobachtungsliste (inkl. Diskussionsseiten).\'\'\'',
+'watchlistcount'       => '\'\'\'Sie haben {{PLURAL:$1|einen Eintrag|$1 Einträge}} auf Ihrer Beobachtungsliste (inkl. Diskussionsseiten).\'\'\'',
 'clearwatchlist'       => 'Beobachtungsliste löschen',
 'watchlistcleartext'   => 'Sind Sie sicher, dass Sie diese vollständig löschen wollen?',
 'watchlistclearbutton' => 'Beobachtungsliste löschen',
-'watchlistcleardone'   => 'Ihre Beobachtungsliste wurde gelöscht. $1 Einträge wurden entfernt.',
+'watchlistcleardone'   => 'Ihre Beobachtungsliste wurde gelöscht. {{PLURAL:$1|Ein Eintrag wurde|$1 Einträge wurden}} entfernt.',
 "watchnologin" => "Sie sind nicht angemeldet",
 'watchnologintext'     => 'Sie müssen [[{{ns:special}}:Userlogin|angemeldet]]
 sein, um Ihre Beobachtungsliste zu bearbeiten.',
@@ -1039,7 +1039,7 @@ Wenn Sie die Seite wieder von Ihrer Beobachtungsliste entfernen möchten, klicke
 "unwatchthispage" => "Nicht mehr beobachten",
 "notanarticle" => "Keine Seite",
 'watchnochange'                => 'Keine der von Ihnen beobachteten Seiten wurde während des angezeigten Zeitraums bearbeitet.',
-'watchdetails' => 'Sie beobachten $1 Seiten | [[{{ns:special}}:Watchlist/edit|Komplette Liste zeigen und bearbeiten]] | [[{{ns:special}}:Watchlist/clear|Komplette Liste leeren]]',
+'watchdetails'         => 'Sie beobachten {{PLURAL:$1|eine Seite|$1 Seiten}} | [[{{ns:special}}:Watchlist/edit|Komplette Liste zeigen und bearbeiten]] | [[{{ns:special}}:Watchlist/clear|Komplette Liste leeren]]',
 'wlheader-enotif'      => 'Der E-Mail-Benachrichtigungsdienst ist aktiviert.<br />',
 'wlheader-showupdated' => 'Seiten mit noch nicht gesehenen Änderungen werden \'\'\'fett\'\'\' dargestellt.<br />',
 "watchmethod-recent" => "Überprüfen der letzten Bearbeitungen für die Beobachtungsliste",
index 681ac70..dbbce49 100644 (file)
@@ -1413,11 +1413,11 @@ or has chosen not to receive e-mail from other users.',
 'watchlistfor' => "(for '''$1''')",
 'nowatchlist'          => 'You have no items on your watchlist.',
 'watchlistanontext' => 'Please $1 to view or edit items on your watchlist.',
-'watchlistcount'       => "'''You have $1 items on your watchlist, including talk pages.'''",
+'watchlistcount'       => "'''You have {{PLURAL:$1|$1 item|$1 items}} on your watchlist, including talk pages.'''",
 'clearwatchlist'       => 'Clear watchlist',
 'watchlistcleartext' => 'Are you sure you wish to remove them?',
 'watchlistclearbutton' => 'Clear watchlist',
-'watchlistcleardone' => 'Your watchlist has been cleared. $1 items were removed.',
+'watchlistcleardone' => 'Your watchlist has been cleared. {{PLURAL:$1|$1 item was|$1 items were}} removed.',
 'watchnologin'         => 'Not logged in',
 'watchnologintext'     => 'You must be [[Special:Userlogin|logged in]] to modify your watchlist.',
 'addedwatch'           => 'Added to watchlist',
@@ -1435,7 +1435,7 @@ If you want to remove the page from your watchlist later, click \"Unwatch\" in t
 'unwatchthispage'      => 'Stop watching',
 'notanarticle'         => 'Not a content page',
 'watchnochange'        => 'None of your watched items was edited in the time period displayed.',
-'watchdetails'         => '* $1 pages watched not counting talk pages
+'watchdetails'         => '* {{PLURAL:$1|$1 page|$1 pages}} watched not counting talk pages
 * [[Special:Watchlist/edit|Show and edit complete watchlist]]
 * [[Special:Watchlist/clear|Remove all pages]]',
 'wlheader-enotif'              => "* E-mail notification is enabled.",