Index: trunk/extensions/FileSearch/FileSearch.php |
— | — | @@ -21,15 +21,9 @@ |
22 | 22 | 'url' => 'http://www.mediawiki.org/wiki/Extension:FileSearch', |
23 | 23 | ); |
24 | 24 | |
25 | | -$wgExtensionFunctions[] = 'efFileSearchSetup'; |
| 25 | +#$wgExtensionFunctions[] = array( 'FileSearchIndexer', 'initialise' ); |
26 | 26 | $wgAutoloadClasses['FileSearchIndexer'] = dirname( __FILE__ ) . '/FileSearchIndexer.php'; |
27 | 27 | $wgAutoloadClasses['Extractor'] = dirname( __FILE__ ) . '/extract/Extractor.php'; |
28 | 28 | $wgFileSearchExtractors['TextExtractor'] = dirname( __FILE__ ) . '/extract/TextExtractor.php'; |
29 | | - |
30 | | -function efFileSearchSetup() { |
31 | | - global $wgHooks; |
32 | | - $wgHooks['FileUpload'][] = 'FileSearchIndexer::upload'; |
33 | | - $wgHooks['SearchUpdate'][] = 'FileSearchIndexer::index'; |
34 | | - #FileSearchIndexer::initialise(); |
35 | | -} |
36 | | - |
| 29 | +$wgHooks['FileUpload'][] = 'FileSearchIndexer::upload'; |
| 30 | +$wgHooks['SearchUpdate'][] = 'FileSearchIndexer::index'; |
Index: trunk/extensions/FundraiserPortal/FundraiserPortal.php |
— | — | @@ -66,16 +66,8 @@ |
67 | 67 | $wgExtensionMessagesFiles['FundraiserPortal'] = |
68 | 68 | dirname( __FILE__ ) . "/FundraiserPortal.i18n.php"; |
69 | 69 | |
70 | | -$wgExtensionFunctions[] = 'efFundraiserPortalSetup'; |
| 70 | +$wgHooks['BeforePageDisplay'][] = 'efFundraiserPortalLoader'; |
71 | 71 | |
72 | | - |
73 | | -// Register hooks |
74 | | -function efFundraiserPortalSetup() { |
75 | | - global $wgHooks; |
76 | | - |
77 | | - $wgHooks['BeforePageDisplay'][] = 'efFundraiserPortalLoader'; |
78 | | -} |
79 | | - |
80 | 72 | // Load the js that will choose the button client side |
81 | 73 | function efFundraiserPortalLoader( $out, $skin ) { |
82 | 74 | global $wgOut, $wgContLang; |
Index: trunk/extensions/geoserver/SpecialWikimaps.php |
— | — | @@ -11,7 +11,6 @@ |
12 | 12 | * @license http://www.gnu.org/copyleft/gpl.html GNU General Public License 2.0 or later |
13 | 13 | */ |
14 | 14 | |
15 | | -$wgExtensionFunctions[] = 'wfSpecialWikimaps'; |
16 | 15 | $wgExtensionCredits['specialpage'][] = array( |
17 | 16 | 'name' => 'Wikimaps', |
18 | 17 | 'author' => 'Jens Frank', |
Index: trunk/extensions/Duplicator/Duplicator.php |
— | — | @@ -23,8 +23,10 @@ |
24 | 24 | $wgExtensionAliasesFiles['Duplicator'] = $dir . 'Duplicator.alias.php'; |
25 | 25 | $wgAutoloadClasses['SpecialDuplicator'] = $dir . 'Duplicator.page.php'; |
26 | 26 | $wgSpecialPages['Duplicator'] = 'SpecialDuplicator'; |
27 | | -$wgExtensionFunctions[] = 'efDuplicator'; |
28 | 27 | |
| 28 | +$wgHooks['SkinTemplateBuildNavUrlsNav_urlsAfterPermalink'][] = 'efDuplicatorNavigation'; |
| 29 | +$wgHooks['SkinTemplateToolboxEnd'][] = 'efDuplicatorToolbox'; |
| 30 | + |
29 | 31 | /** |
30 | 32 | * User permissions |
31 | 33 | */ |
— | — | @@ -37,15 +39,6 @@ |
38 | 40 | $wgDuplicatorRevisionLimit = 250; |
39 | 41 | |
40 | 42 | /** |
41 | | - * Extension setup function |
42 | | - */ |
43 | | -function efDuplicator() { |
44 | | - global $wgHooks; |
45 | | - $wgHooks['SkinTemplateBuildNavUrlsNav_urlsAfterPermalink'][] = 'efDuplicatorNavigation'; |
46 | | - $wgHooks['SkinTemplateToolboxEnd'][] = 'efDuplicatorToolbox'; |
47 | | -} |
48 | | - |
49 | | -/** |
50 | 43 | * Build the link to be shown in the toolbox if appropriate |
51 | 44 | */ |
52 | 45 | function efDuplicatorNavigation( &$skin, &$nav_urls, &$oldid, &$revid ) { |
Index: trunk/extensions/Contributors/Contributors.php |
— | — | @@ -13,7 +13,6 @@ |
14 | 14 | exit( 1 ); |
15 | 15 | } |
16 | 16 | |
17 | | -$wgExtensionFunctions[] = 'efContributors'; |
18 | 17 | $wgExtensionCredits['specialpage'][] = array( |
19 | 18 | 'path' => __FILE__, |
20 | 19 | 'name' => 'Contributors', |
— | — | @@ -30,6 +29,12 @@ |
31 | 30 | $wgSpecialPages['Contributors'] = 'SpecialContributors'; |
32 | 31 | $wgSpecialPageGroups['Contributors'] = 'pages'; |
33 | 32 | |
| 33 | +$wgHooks['ArticleDeleteComplete'][] = 'efContributorsInvalidateCache'; |
| 34 | +$wgHooks['ArticleSaveComplete'][] = 'efContributorsInvalidateCache'; |
| 35 | +# Good god, this is ludicrous! |
| 36 | +$wgHooks['SkinTemplateBuildNavUrlsNav_urlsAfterPermalink'][] = 'efContributorsNavigation'; |
| 37 | +$wgHooks['SkinTemplateToolboxEnd'][] = 'efContributorsToolbox'; |
| 38 | + |
34 | 39 | /** |
35 | 40 | * Intelligent cut-off limit; see below |
36 | 41 | */ |
— | — | @@ -42,19 +47,6 @@ |
43 | 48 | $wgContributorsThreshold = 2; |
44 | 49 | |
45 | 50 | /** |
46 | | - * Extension initialisation function |
47 | | - */ |
48 | | -function efContributors() { |
49 | | - global $wgHooks; |
50 | | - |
51 | | - $wgHooks['ArticleDeleteComplete'][] = 'efContributorsInvalidateCache'; |
52 | | - $wgHooks['ArticleSaveComplete'][] = 'efContributorsInvalidateCache'; |
53 | | - # Good god, this is ludicrous! |
54 | | - $wgHooks['SkinTemplateBuildNavUrlsNav_urlsAfterPermalink'][] = 'efContributorsNavigation'; |
55 | | - $wgHooks['SkinTemplateToolboxEnd'][] = 'efContributorsToolbox'; |
56 | | -} |
57 | | - |
58 | | -/** |
59 | 51 | * Invalidate the cache we saved for a given title |
60 | 52 | * |
61 | 53 | * @param $article Article object that changed |
Index: trunk/extensions/Description/Description.php |
— | — | @@ -29,7 +29,6 @@ |
30 | 30 | |
31 | 31 | define('DESCRIPTION_VERSION', '0.1'); |
32 | 32 | |
33 | | -$wgExtensionFunctions[] = 'DescriptionSetup'; |
34 | 33 | $wgExtensionCredits['other'][] = array( |
35 | 34 | 'path' => __FILE__, |
36 | 35 | 'name' => 'Description', |
— | — | @@ -38,12 +37,7 @@ |
39 | 38 | 'url' => 'http://www.mediawiki.org/wiki/Extension:Description', |
40 | 39 | 'description' => 'Adds a description meta-tag to MW pages'); |
41 | 40 | |
42 | | -function DescriptionSetup() { |
43 | | - |
44 | | - global $wgHooks; |
45 | | - |
46 | | - $wgHooks['ArticleViewHeader'][] = 'DescriptionArticleViewHeader'; |
47 | | -} |
| 41 | +$wgHooks['ArticleViewHeader'][] = 'DescriptionArticleViewHeader'; |
48 | 42 | |
49 | 43 | function DescriptionArticleViewHeader(&$article, &$outputDone = null, &$pcache = null) { |
50 | 44 | global $wgOut; |