summaryrefslogtreecommitdiff
path: root/languages/LanguageVec.php
blob: a87ddd8e2c771379c71d5a6a8b099d0bbac8eed4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
<?php
/** Venitian ( Vèneto )
  *
  * @package MediaWiki
  * @subpackage Language
  */

require_once( 'LanguageIt.php' );

if (!$wgCachedMessageArrays) {
	require_once('MessagesVec.php');
}

class LanguageVec extends LanguageIt {
	private $mMessagesVec, $mNamespaceNamesVec = null;

	private $mQuickbarSettingsVec = array(
		'Nessun', 'Fisso a sinistra', 'Fisso a destra', 'Fluttuante a sinistra'
	);

	function __construct() {
		parent::__construct();

		global $wgAllMessagesVec;
		$this->mMessagesVec =& $wgAllMessagesVec;

		global $wgMetaNamespace;
		$this->mNamespaceNamesVec = array(		
			NS_MEDIA            => 'Media',
			NS_SPECIAL          => 'Speciale',
			NS_MAIN             => '',
			NS_TALK             => 'Discussion',
			NS_USER             => 'Utente',
			NS_USER_TALK        => 'Discussion_utente',
			NS_PROJECT          => $wgMetaNamespace,
			NS_PROJECT_TALK     => 'Discussion_' . $wgMetaNamespace,
			NS_IMAGE            => 'Imagine',
			NS_IMAGE_TALK       => 'Discussion_imagine',
			NS_MEDIAWIKI        => 'MediaWiki',
			NS_MEDIAWIKI_TALK   => 'Discussion_MediaWiki',
			NS_TEMPLATE         => 'Template',
			NS_TEMPLATE_TALK    => 'Discussion_template',
			NS_HELP             => 'Aiuto',
			NS_HELP_TALK        => 'Discussion_aiuto',
			NS_CATEGORY         => 'Categoria',
			NS_CATEGORY_TALK    => 'Discussion_categoria'
		);

	}

	function getFallbackLanguage() {
		return 'it';
	}

	function getNamespaces() {
		return $this->mNamespaceNamesVec + parent::getNamespaces();
	}

	function getQuickbarSettings() {
		return $this->mQuickbarSettingsVec;
	}

	function getMessage( $key ) {
		if( isset( $this->mMessagesVec[$key] ) ) {
			return $this->mMessagesVec[$key];
		} else {
			return parent::getMessage( $key );
		}
	}

	function getAllMessages() {
		return $this->mMessagesVec;
	}

}

?>