Shirayuki has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/53035


Change subject: Adding comments for grep
......................................................................

Adding comments for grep

Change-Id: I9d4885dd758d9877e05b0e87638f7e1ca366c518
---
M ProtectSite.body.php
1 file changed, 20 insertions(+), 0 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/ProtectSite 
refs/changes/35/53035/1

diff --git a/ProtectSite.body.php b/ProtectSite.body.php
index 6d29a65..4bee26f 100644
--- a/ProtectSite.body.php
+++ b/ProtectSite.body.php
@@ -172,6 +172,9 @@
         * @return string HTML fieldset
         */
        private function fieldset( $name, $content ) {
+               // Give grep a chance to find the usages:
+               // protectsite-title, protectsite-createaccount, 
protectsite-createpage,
+               // protectsite-edit, protectsite-move, protectsite-upload
                return '<fieldset><legend>' . wfMsg( 'protectsite-' . $name ) .
                        "</legend>\n" . $content . "\n</fieldset>\n";
        }
@@ -181,6 +184,12 @@
         * This was fixed in r16320 of the MW source; WM bugzilla bug #7188.
         */
        private function radiobox( $varname, $fields ) {
+               // Give grep a chance to find the usages:
+               // protectsite-createaccount-0, protectsite-createaccount-1, 
protectsite-createaccount-2,
+               // protectsite-createpage-0, protectsite-createpage-1, 
protectsite-createpage-2,
+               // protectsite-edit-0, protectsite-edit-1, protectsite-edit-2,
+               // protectsite-move-0, protectsite-move-1,
+               // protectsite-upload-0, protectsite-upload-1
                $s = '';
                foreach( $fields as $value => $checked ) {
                        $s .= "<div><label><input type=\"radio\" 
name=\"{$varname}\" value=\"{$value}\"" . ( $checked ? ' checked="checked"' : 
'' ) . ' />'
@@ -200,6 +209,8 @@
                        $value = $this->mRequest->getText( $varname, $value );
                }
 
+               // Give grep a chance to find the usages:
+               // protectsite-timeout,  protectsite-comment, 
protectsite-ucomment
                $value = htmlspecialchars( $value );
                return '<div><label>' . wfMsg( 'protectsite-' . $varname ) .
                                "<input type=\"text\" name=\"{$varname}\" 
value=\"{$value}\" /> " .
@@ -209,6 +220,15 @@
 
        /* This function outputs the field status. */
        private function showField( $name, $state ) {
+               // Give grep a chance to find the usages:
+               //   protectsite-createaccount, protectsite-createpage, 
protectsite-edit,
+               //   protectsite-move, protectsite-upload
+               // Give grep a chance to find the usages:
+               //   protectsite-createaccount-0, protectsite-createaccount-1, 
protectsite-createaccount-2,
+               //   protectsite-createpage-0, protectsite-createpage-1, 
protectsite-createpage-2,
+               //   protectsite-edit-0, protectsite-edit-1, protectsite-edit-2,
+               //   protectsite-move-0, protectsite-move-1,
+               //   protectsite-upload-0, protectsite-upload-1
                return '<b>' . wfMsg( 'protectsite-' . $name ) . ' - <i>' .
                                        '<span style="color: ' . ( ( $state > 0 
) ? 'red' : 'green' ) . '">' .
                                        wfMsg( 'protectsite-' . $name . '-' . 
$state ) . '</span>' .

-- 
To view, visit https://gerrit.wikimedia.org/r/53035
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I9d4885dd758d9877e05b0e87638f7e1ca366c518
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/ProtectSite
Gerrit-Branch: master
Gerrit-Owner: Shirayuki <[email protected]>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to