r14648 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r14647‎ | r14648 | r14649 >
Date:20:36, 7 June 2006
Author:nikerabbit
Status:old
Tags:
Comment:
* Restructured
Modified paths:
  • /trunk/phase3/languages/LanguageAf.php (modified) (history)

Diff [purge]

Index: trunk/phase3/languages/LanguageAf.php
@@ -7,68 +7,77 @@
88
99 require_once( 'LanguageUtf8.php' );
1010
11 -/* private */ $wgNamespaceNamesAf = array(
12 - NS_MEDIA => "Media",
13 - NS_SPECIAL => "Spesiaal",
14 - NS_MAIN => "",
15 - NS_TALK => "Bespreking",
16 - NS_USER => "Gebruiker",
17 - NS_USER_TALK => "Gebruikerbespreking",
18 - NS_PROJECT => $wgMetaNamespace,
19 - NS_PROJECT_TALK => $wgMetaNamespace."bespreking",
20 - NS_IMAGE => "Beeld",
21 - NS_IMAGE_TALK => "Beeldbespreking",
22 - NS_MEDIAWIKI => "MediaWiki",
23 - NS_MEDIAWIKI_TALK => "MediaWikibespreking",
24 - NS_TEMPLATE => 'Sjabloon',
25 - NS_TEMPLATE_TALK => 'Sjabloonbespreking',
26 - NS_HELP => 'Hulp',
27 - NS_HELP_TALK => 'Hulpbespreking',
28 - NS_CATEGORY => 'Kategorie',
29 - NS_CATEGORY_TALK => 'Kategoriebespreking'
30 -) + $wgNamespaceNamesEn;
31 -
32 -/* private */ $wgQuickbarSettingsAf = array(
33 - "Geen.", "Links vas.", "Regs vas.", "Dryf links."
34 -);
35 -
36 -/* private */ $wgSkinNamesAf = array(
37 - 'standard' => "Standaard",
38 - 'nostalgia' => "Nostalgie",
39 - 'cologneblue' => "Keulen blou",
40 -) + $wgSkinNamesEn;
41 -
4211 if (!$wgCachedMessageArrays) {
4312 require_once('MessagesAf.php');
4413 }
4514
46 -
4715 class LanguageAf extends LanguageUtf8 {
 16+ private $mMessagesAf, $mNamespaceNamesAf = null;
4817
 18+ private $mQuickbarSettingsAf = array(
 19+ "Geen.", "Links vas.", "Regs vas.", "Dryf links."
 20+ );
 21+
 22+ private $mSkinNamesAf = array(
 23+ 'standard' => "Standaard",
 24+ 'nostalgia' => "Nostalgie",
 25+ 'cologneblue' => "Keulen blou",
 26+ );
 27+
 28+ function LanguageAf() {
 29+ LanguageUtf8::LanguageUtf8();
 30+
 31+ global $wgAllMessagesAf;
 32+ $this->mMessagesAf =& $wgAllMessagesAf;
 33+
 34+ global $wgMetaNamespace;
 35+ $this->mNamespaceNamesAf = array(
 36+ NS_MEDIA => "Media",
 37+ NS_SPECIAL => "Spesiaal",
 38+ NS_MAIN => "",
 39+ NS_TALK => "Bespreking",
 40+ NS_USER => "Gebruiker",
 41+ NS_USER_TALK => "Gebruikerbespreking",
 42+ NS_PROJECT => $wgMetaNamespace,
 43+ NS_PROJECT_TALK => $wgMetaNamespace."bespreking",
 44+ NS_IMAGE => "Beeld",
 45+ NS_IMAGE_TALK => "Beeldbespreking",
 46+ NS_MEDIAWIKI => "MediaWiki",
 47+ NS_MEDIAWIKI_TALK => "MediaWikibespreking",
 48+ NS_TEMPLATE => 'Sjabloon',
 49+ NS_TEMPLATE_TALK => 'Sjabloonbespreking',
 50+ NS_HELP => 'Hulp',
 51+ NS_HELP_TALK => 'Hulpbespreking',
 52+ NS_CATEGORY => 'Kategorie',
 53+ NS_CATEGORY_TALK => 'Kategoriebespreking'
 54+ );
 55+
 56+ }
 57+
4958 function getNamespaces() {
50 - global $wgNamespaceNamesAf;
51 - return $wgNamespaceNamesAf;
 59+ return $this->mNamespaceNamesAf + parent::getNamespaces();
5260 }
5361
5462 function getQuickbarSettings() {
55 - global $wgQuickbarSettingsAf;
56 - return $wgQuickbarSettingsAf;
 63+ return $this->mQuickbarSettingsAf;
5764 }
5865
5966 function getSkinNames() {
60 - global $wgSkinNamesAf;
61 - return $wgSkinNamesAf;
 67+ return $this->mSkinNamesAf + parent::getSkinNames();
6268 }
6369
6470 function getMessage( $key ) {
65 - global $wgAllMessagesAf;
66 - if( isset( $wgAllMessagesAf[$key] ) ) {
67 - return $wgAllMessagesAf[$key];
 71+ if( isset( $this->mMessagesAf[$key] ) ) {
 72+ return $this->mMessagesAf[$key];
6873 } else {
6974 return parent::getMessage( $key );
7075 }
7176 }
7277
 78+ function getAllMessages() {
 79+ return $this->mMessagesAf;
 80+ }
 81+
7382 # South Africa uses space for thousands and comma for decimal
7483 # Reference: AWS Reël 7.4 p. 52, 2002 edition
7584 # glibc is wrong in this respect in some versions

Status & tagging log