Shirayuki has uploaded a new change for review.

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


Change subject: Give grep a chance to find the usages
......................................................................

Give grep a chance to find the usages

Change-Id: I3c56f4ae674da12fb882f89001f368eecfc8e5ea
---
M ExtendedSearch/includes/SearchIndex/SearchIndex.class.php
M ExtendedSearch/views/view.SearchResult.php
M InsertMagic/InsertMagic.class.php
M Review/SpecialReview.class.php
M Statistics/lib/Charting.class.php
M Statistics/views/view.DiagramStepII.php
M WikiAdmin/SpecialWikiAdmin.class.php
7 files changed, 49 insertions(+), 0 deletions(-)


  git pull 
ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/BlueSpiceExtensions 
refs/changes/59/79559/1

diff --git a/ExtendedSearch/includes/SearchIndex/SearchIndex.class.php 
b/ExtendedSearch/includes/SearchIndex/SearchIndex.class.php
index 177cc03..b7ee495 100644
--- a/ExtendedSearch/includes/SearchIndex/SearchIndex.class.php
+++ b/ExtendedSearch/includes/SearchIndex/SearchIndex.class.php
@@ -741,6 +741,8 @@
        protected function createErrorMessageView( $message ) {
                $res = new ViewBaseElement();
                $res->setTemplate( '<div id="bs-es-searchterm-error">' . 
wfMessage( 'bs-extendedsearch-error' )->plain() . ': {message}</div>' );
+               // Give grep a chance to find the usages:
+               // bs-extendedsearch-no_search_term, 
bs-extendedsearch-invalid-query
                $res->addData( array( 'message' => wfMessage( 
'bs-extendedsearch-' . $message )->plain() ) );
                return $res;
        }
diff --git a/ExtendedSearch/views/view.SearchResult.php 
b/ExtendedSearch/views/view.SearchResult.php
index 5a5641b..5954d49 100644
--- a/ExtendedSearch/views/view.SearchResult.php
+++ b/ExtendedSearch/views/view.SearchResult.php
@@ -286,6 +286,8 @@
                        }
                        if ( $active ) $aOut .= '<b>';
                        $aOut .= '<a 
href="'.$sortUrl.'&search_asc='.$direction.'&search_order='.$sort.'">';
+                       // Give grep a chance to find the usages: 
bs-extendedsearch-sort-relevance,
+                       // bs-extendedsearch-sort-title, 
bs-extendedsearch-sort-ts, bs-extendedsearch-sort-type
                        $aOut .= wfMessage( 'bs-extendedsearch-' . $i18nKey 
)->plain() . '</a>';
                        $aOut .= '&nbsp;' . $icon;
                        if ( $active ) $aOut .= '</b>';
diff --git a/InsertMagic/InsertMagic.class.php 
b/InsertMagic/InsertMagic.class.php
index e4036b0..e42a9b4 100644
--- a/InsertMagic/InsertMagic.class.php
+++ b/InsertMagic/InsertMagic.class.php
@@ -205,12 +205,31 @@
                        $oDescriptor->id = $sTag;
                        $oDescriptor->type = 'tag';
                        $oDescriptor->name = $sTag;
+                       // Give grep a chance to find the usages:
+                       // bs-insertmagic-gallery-code, 
bs-insertmagic-nowiki-code, bs-insertmagic-noinclude-code,
+                       // bs-insertmagic-includeonly-code, 
bs-insertmagic-redirect-code,bs-insertmagic-gallery,
+                       // bs-insertmagic-nowiki, bs-insertmagic-noinclude, 
bs-insertmagic-includeonly,
+                       // bs-insertmagic-redirect
                        $oDescriptor->desc = wfMessage( 'bs-insertmagic-'.$sTag 
)->parse();
                        $oDescriptor->code = wfMessage( 
'bs-insertmagic-'.$sTag.'-code' )->plain();
                        $oDescriptor->previewable = true;
                        $oResponse->result[] = $oDescriptor;
                }
 
+               // Give grep a chance to find the usages:
+               // bs-insertmagic-{{CURRENTYEAR}}, 
bs-insertmagic-{{CURRENTMONTH}},bs-insertmagic-{{CURRENTMONTHNAME}},
+               // bs-insertmagic-{{CURRENTMONTHNAMEGEN}}, 
bs-insertmagic-{{CURRENTMONTHABBREV}},
+               // bs-insertmagic-{{CURRENTDAY}}, 
bs-insertmagic-{{CURRENTDAY2}}, bs-insertmagic-{{CURRENTDOW}},
+               // bs-insertmagic-{{CURRENTDAYNAME}}, 
bs-insertmagic-{{CURRENTTIME}}, bs-insertmagic-{{CURRENTHOUR}},
+               // bs-insertmagic-{{CURRENTWEEK}}, 
bs-insertmagic-{{CURRENTTIMESTAMP}}, bs-insertmagic-{{SITENAME}},
+               // bs-insertmagic-{{SERVER}}, bs-insertmagic-{{SERVERNAME}}, 
bs-insertmagic-{{SCRIPTPATH}},
+               // bs-insertmagic-{{STYLEPATH}}, 
bs-insertmagic-{{CURRENTVERSION}}, bs-insertmagic-{{CONTENTLANGUAGE}},
+               // bs-insertmagic-{{PAGEID}}, bs-insertmagic-{{PAGESIZE:"page 
name"}},
+               // bs-insertmagic-{{PROTECTIONLEVEL:"action"}}, 
bs-insertmagic-{{REVISIONID}},
+               // bs-insertmagic-{{REVISIONDAY}}, 
bs-insertmagic-{{REVISIONDAY2}}, bs-insertmagic-{{REVISIONMONTH}},
+               // bs-insertmagic-{{REVISIONMONTH1}}, 
bs-insertmagic-{{REVISIONYEAR}},
+               // bs-insertmagic-{{REVISIONTIMESTAMP}}, 
bs-insertmagic-{{REVISIONUSER}},
+               // bs-insertmagic-{{DISPLAYTITLE:"title"}}, 
bs-insertmagic-{{DEFAULTSORT:"sortkey"}}
                foreach( self::$aMagicWords['variables'] as $sVariable ) {
                        $oDescriptor = new stdClass();
                        $oDescriptor->id = $sVariable;
@@ -227,6 +246,12 @@
                        $oDescriptor->id = $sSwitch;
                        $oDescriptor->type = 'switch';
                        $oDescriptor->name = substr( $sSwitch, 2, -2 );
+                       // Give grep a chance to find the usages:
+                       // bs-insertmagic-__NOTOC__, 
bs-insertmagic-__FORCETOC__, bs-insertmagic-__TOC__,
+                       // bs-insertmagic-__NOEDITSECTION__, 
bs-insertmagic-__NEWSECTIONLINK__,
+                       // bs-insertmagic-__NONEWSECTIONLINK__, 
bs-insertmagic-__NOGALLERY__, bs-insertmagic-__HIDDENCAT__,
+                       // bs-insertmagic-__NOCONTENTCONVERT__, 
bs-insertmagic-__NOTITLECONVERT__, bs-insertmagic-__END__,
+                       // bs-insertmagic-__INDEX__, 
bs-insertmagic-__NOINDEX__, bs-insertmagic-__STATICREDIRECT__
                        $oDescriptor->desc = wfMessage( 
'bs-insertmagic-'.$sSwitch )->parse();
                        $oDescriptor->code = $sSwitch;
                        $oDescriptor->previewable = false;
diff --git a/Review/SpecialReview.class.php b/Review/SpecialReview.class.php
index d440eaa..c7c9db3 100644
--- a/Review/SpecialReview.class.php
+++ b/Review/SpecialReview.class.php
@@ -156,6 +156,8 @@
                                $sOutput.= '<tr' . $class . '>';
                                $sOutput.= '<td valign="top">' . 
$oLinker->makeLinkObj($title, $row['page_title']) . '</td>';
                                $sOutput.= '<td valign="top">' . 
$row['owner_name'] . '</td>';
+                               // Give grep a chance to find the usages:
+                               // bs-review-vote, bs-review-sign, 
bs-review-comment, bs-review-workflow
                                $sOutput.= '<td valign="top">' . wfMsg( 
'bs-review-' . $row['rev_mode']) . '</td>';
 
                                if ($bShowAssessor) {
@@ -194,6 +196,8 @@
                                if( $arrValue['revs_status'] == '' ) {
                                        $arrValue['revs_status'] = 'pending';
                                }
+                               // Give grep a chance to find the usages:
+                               // bs-review-pending, bs-review-denied, 
bs-review-nothing
                                $sOutput.= wfMsg( 'bs-review-' . 
$arrValue['revs_status']);
 
                                $sOutput.= '</td>';
diff --git a/Statistics/lib/Charting.class.php 
b/Statistics/lib/Charting.class.php
index 603b225..d001443 100644
--- a/Statistics/lib/Charting.class.php
+++ b/Statistics/lib/Charting.class.php
@@ -55,6 +55,8 @@
                $intervals = Interval::getIntervalsFromDiagram( $oDiagram );
                $oDiagram->addFilterText( wfMsg( 'bs-statistics-from-to', 
$oDiagram->getStartTime(), $oDiagram->getEndTime() ) );
                // TODO MRG (20.12.10 00:19): This should be getModeText
+               // Give grep a chance to find the usages:
+               // bs-statistics-aggregated, bs-statistics-grouped, 
bs-statistics-normal, bs-statistics-absolute
                $oDiagram->addFilterText( "\n".wfMsg( 'bs-statistics-mode' ).": 
".wfMsg( 'bs-statistics-'.$oDiagram->getMode() ) );
                // PostgreSQL-Check (uses mwuser instead of user)
                global $wgDBtype;
@@ -89,6 +91,8 @@
                set_time_limit(120);
                $intervals = Interval::getIntervalsFromDiagram( $oDiagram );
                $oDiagram->addFilterText( wfMsg( 'bs-statistics-from-to', 
$oDiagram->getStartTime(), $oDiagram->getEndTime() ) );
+               // Give grep a chance to find the usages:
+               // bs-statistics-aggregated, bs-statistics-grouped, 
bs-statistics-normal, bs-statistics-absolute
                $oDiagram->addFilterText( "<br/>".wfMsg( 'bs-statistics-mode' 
).": ".wfMsg( 'bs-statistics-'.$oDiagram->getMode() ) );
                // PostgreSQL-Check (uses mwuser instead of user)
                global $wgDBtype;
diff --git a/Statistics/views/view.DiagramStepII.php 
b/Statistics/views/view.DiagramStepII.php
index 6137de2..f6e842a 100644
--- a/Statistics/views/view.DiagramStepII.php
+++ b/Statistics/views/view.DiagramStepII.php
@@ -212,6 +212,8 @@
                        $sTempOut = '';
                        $sTempOut .= '          <option value="'.$sGrain.'"';
                        if ( $sGrain == $this->sActiveGrain ) $sTempOut .= ' 
selected="selected"';
+                       // Give grep a chance to find the usages:
+                       // bs-statistics-Y, bs-statistics-m, bs-statistics-W, 
bs-statistics-d
                        $sTempOut .= '>'.wfMsg( 'bs-statistics-' . $sGrain 
).'</option>';
                        $aOut[] = $sTempOut;
                }
diff --git a/WikiAdmin/SpecialWikiAdmin.class.php 
b/WikiAdmin/SpecialWikiAdmin.class.php
index 187eb23..a924006 100644
--- a/WikiAdmin/SpecialWikiAdmin.class.php
+++ b/WikiAdmin/SpecialWikiAdmin.class.php
@@ -30,6 +30,11 @@
                                $wa_mode_Instance = $moduleInstance;
 
                                $moduleNameLower = strtolower( $moduleName );
+                               // Give grep a chance to find the usages:
+                               // bs-extendedsearch-label, 
bs-extendedsearchadmin-label, bs-extendedsearch-label,
+                               // bs-extendedsearchadmin-label, 
bs-extensioninfo-label, bs-groupmanager-label,
+                               // bs-interwikilinks-label, 
bs-namespacemanager-label, bs-pagetemplatesadmin-label,
+                               // bs-permissionmanager-label, 
bs-preferences-label, bs-usermanager-label
                                $wgOut->setPagetitle( 'WikiAdmin - ' . wfMsg( 
'bs-' . $moduleNameLower.'-label' ) );
                        }
                }
@@ -56,6 +61,11 @@
                        $form .= '<a href="'.$url.'">';
                        $form .= '<img src="'.BsConfig::get( 'MW::ScriptPath' 
).$params['image'].'" alt="'.$module.'" title="'.$module.'">';
                        $form .= '<div class="bs-admin-label">';
+                       // Give grep a chance to find the usages:
+                       // bs-extendedsearch-label, 
bs-extendedsearchadmin-label, bs-extendedsearch-label,
+                       // bs-extendedsearchadmin-label, 
bs-extensioninfo-label, bs-groupmanager-label,
+                       // bs-interwikilinks-label, bs-namespacemanager-label, 
bs-pagetemplatesadmin-label,
+                       // bs-permissionmanager-label, bs-preferences-label, 
bs-usermanager-label
                        $form .= wfMsg( 'bs-' . $moduleNameLower . '-label' );
                        $form .= '</div>';
                        $form .= '</a>';

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

Gerrit-MessageType: newchange
Gerrit-Change-Id: I3c56f4ae674da12fb882f89001f368eecfc8e5ea
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/BlueSpiceExtensions
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