From d9e0154b62a7378df066bf7f47879861271c6a3a Mon Sep 17 00:00:00 2001 From: Happy-melon Date: Sun, 30 Aug 2009 21:50:10 +0000 Subject: [PATCH] * Allow IndexPager->mLimitsShown to be an associative array of limit => text-to-display-in-limit-form pairs. * Use this to add an "all" value to the limit form in Special:AllMessages. In reality, "all" is only 5000, but this is plenty more than most wikis should have. --- RELEASE-NOTES | 2 ++ includes/Pager.php | 4 ++-- includes/specials/SpecialAllmessages.php | 5 +++++ languages/messages/MessagesEn.php | 1 + 4 files changed, 10 insertions(+), 2 deletions(-) diff --git a/RELEASE-NOTES b/RELEASE-NOTES index ead2b92615..e27a4ac4aa 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -160,6 +160,8 @@ this. Was used when mwEmbed was going to be an extension. * (bug 9691) Add type (signup or login) parameter to AuthPlugin::ModifyUITemplate() * (bug 14454) "Member of group(s)" in Special:Preferences causes language difficulties * (bug 16697) Unicode combining characters are difficult to edit in some browsers +* IndexPager->mLimitsShown can now be an associative array of limit => text-to- + display-in-limit-form. * Parser test supports uploading results to remote CodeReview instance * (bug 20013) Added CSS class "mw-version-ext-version" is wrapped on the extension version in Special:Version diff --git a/includes/Pager.php b/includes/Pager.php index 054ca38286..2aef1baaaa 100644 --- a/includes/Pager.php +++ b/includes/Pager.php @@ -879,9 +879,9 @@ abstract class TablePager extends IndexPager { function getLimitSelect() { global $wgLang; $s = ""; diff --git a/includes/specials/SpecialAllmessages.php b/includes/specials/SpecialAllmessages.php index f762532b35..340eebc295 100644 --- a/includes/specials/SpecialAllmessages.php +++ b/includes/specials/SpecialAllmessages.php @@ -128,6 +128,7 @@ class AllmessagesTablePager extends TablePager { var $messages = null; var $talkPages = null; + public $mLimitsShown; function __construct( $page, $conds, $langObj = null ) { parent::__construct(); @@ -135,6 +136,10 @@ class AllmessagesTablePager extends TablePager { $this->mPage = $page; $this->mConds = $conds; $this->mDefaultDirection = true; // always sort ascending + // We want to have an option for people to view *all* the messages, + // so they can use Ctrl+F to search them. 5000 is the maximum that + // will get through WebRequest::getLimitOffset(). + $this->mLimitsShown = array( 20, 50, 100, 250, 500, 5000 => wfMsg('messagesall') ); global $wgLang, $wgContLang, $wgRequest; diff --git a/languages/messages/MessagesEn.php b/languages/messages/MessagesEn.php index 3e43790785..bee1158f33 100644 --- a/languages/messages/MessagesEn.php +++ b/languages/messages/MessagesEn.php @@ -3814,6 +3814,7 @@ Others will be hidden by default. 'watchlistall2' => 'all', 'namespacesall' => 'all', 'monthsall' => 'all', +'messagesall' => 'all', # E-mail address confirmation 'confirmemail' => 'Confirm e-mail address', -- 2.20.1