Index: branches/querypage-work2/extensions/ProofreadPage/ProofreadPage.php |
— | — | @@ -20,6 +20,7 @@ |
21 | 21 | } |
22 | 22 | |
23 | 23 | $wgExtensionFunctions[] = 'wfProofreadPage'; |
| 24 | +$wgRunHooks['wgQueryPages'][] = 'wfProofreadPageAddQueryPages'; |
24 | 25 | |
25 | 26 | $dir = dirname( __FILE__ ) . '/'; |
26 | 27 | $wgExtensionMessagesFiles['ProofreadPage'] = $dir . 'ProofreadPage.i18n.php'; |
— | — | @@ -37,10 +38,9 @@ |
38 | 39 | ); |
39 | 40 | |
40 | 41 | # special page |
41 | | -$wgAutoloadClasses['IndexPagesPage'] = $dir . 'SpecialProofreadPages.php'; |
42 | | -$wgSpecialPages['IndexPages'] = 'IndexPagesPage'; |
43 | | -$wgSpecialPageGroups['IndexPages'] = 'pages' |
44 | | -$wgQueryPages['IndexPagesPage'] = 'IndexPages'; |
| 42 | +$wgAutoloadClasses['ProofreadPages'] = $dir . 'SpecialProofreadPages.php'; |
| 43 | +$wgSpecialPages['IndexPages'] = 'ProofreadPages'; |
| 44 | +$wgSpecialPageGroups['IndexPages'] = 'pages'; |
45 | 45 | |
46 | 46 | # special page |
47 | 47 | $wgAutoloadClasses['PagesWithoutScans'] = $dir . 'SpecialPagesWithoutScans.php'; |
— | — | @@ -83,3 +83,9 @@ |
84 | 84 | new ProofreadPage; |
85 | 85 | return true; |
86 | 86 | } |
| 87 | + |
| 88 | +function wfProofreadPageAddQueryPages( &$wgQueryPages ) { |
| 89 | + $wgQueryPages['ProofreadPages'] = 'IndexPages'; |
| 90 | + $wgQueryPages['PagesWithoutScans'] = 'PagesWithoutScans'; |
| 91 | + return true; |
| 92 | +} |