r49866 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r49865‎ | r49866 | r49867 >
Date:10:09, 25 April 2009
Author:aaron
Status:ok
Tags:
Comment:
* Added actionfailed message
* Pass some flaggedrevs input vars by value
Modified paths:
  • /trunk/extensions/FlaggedRevs/FlaggedRevs.hooks.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/FlaggedRevs.php (modified) (history)
  • /trunk/extensions/FlaggedRevs/flaggedrevs.js (modified) (history)
  • /trunk/phase3/languages/messages/MessagesEn.php (modified) (history)
  • /trunk/phase3/maintenance/language/messages.inc (modified) (history)

Diff [purge]

Index: trunk/phase3/maintenance/language/messages.inc
@@ -1635,6 +1635,7 @@
16361636 'historywarning',
16371637 'confirmdeletetext',
16381638 'actioncomplete',
 1639+ 'actionfailed',
16391640 'deletedtext',
16401641 'deletedarticle',
16411642 'suppressedarticle',
Index: trunk/phase3/languages/messages/MessagesEn.php
@@ -2415,6 +2415,7 @@
24162416 'confirmdeletetext' => 'You are about to delete a page along with all of its history.
24172417 Please confirm that you intend to do this, that you understand the consequences, and that you are doing this in accordance with [[{{MediaWiki:Policy-url}}|the policy]].',
24182418 'actioncomplete' => 'Action complete',
 2419+'actionfailed' => 'Action failed',
24192420 'deletedtext' => '"<nowiki>$1</nowiki>" has been deleted.
24202421 See $2 for a record of recent deletions.',
24212422 'deletedarticle' => 'deleted "[[$1]]"',
Index: trunk/extensions/FlaggedRevs/FlaggedRevs.php
@@ -266,7 +266,7 @@
267267 $wgAvailableRights[] = 'stablesettings';
268268
269269 # Bump this number every time you change flaggedrevs.css/flaggedrevs.js
270 -$wgFlaggedRevStyleVersion = 58;
 270+$wgFlaggedRevStyleVersion = 59;
271271
272272 $wgExtensionFunctions[] = 'efLoadFlaggedRevs';
273273
Index: trunk/extensions/FlaggedRevs/FlaggedRevs.hooks.php
@@ -39,7 +39,8 @@
4040 $ajaxReview = Xml::encodeJsVar( (object) array(
4141 'sendingMsg' => wfMsgHtml('revreview-submitting'),
4242 'sentMsg' => wfMsgHtml('revreview-finished'),
43 - 'actioncomplete' => wfMsgHtml('actioncomplete')
 43+ 'actioncomplete' => wfMsgHtml('actioncomplete'),
 44+ 'actionfailed' => wfMsgHtml('actionfailed')
4445 )
4546 );
4647
@@ -790,8 +791,8 @@
791792 /**
792793 * When an user makes a null-edit we sometimes want to review it...
793794 */
794 - public static function maybeNullEditReview( $article, $user, &$text, &$summary, &$m, &$a, &$b,
795 - &$f, $rev, &$s, $baseId )
 795+ public static function maybeNullEditReview( $article, $user, $text, $summary, $m, $a, $b,
 796+ $flags, $rev, &$status, $baseId )
796797 {
797798 global $wgRequest;
798799 # Must be in reviewable namespace
Index: trunk/extensions/FlaggedRevs/flaggedrevs.js
@@ -235,7 +235,8 @@
236236 wgAjaxReview = {
237237 sendingMsg: "Submitting...",
238238 sentMsg: "Submitted",
239 - actioncomplete: "Action complete"
 239+ actioncomplete: "Action complete",
 240+ actionfailed: "Action failed"
240241 };
241242 }
242243
@@ -349,8 +350,10 @@
350351 }
351352 if( response.indexOf('<suc#>') == 0 ) {
352353 wgAjaxReview.unlockForm();
 354+ document.title = wgAjaxReview.actioncomplete;
 355+ } else {
 356+ document.title = wgAjaxReview.actionfailed;
353357 }
354 - document.title = wgAjaxReview.actioncomplete;
355358 };
356359
357360 wgAjaxReview.onLoad = function() {

Status & tagging log