Tweak wording
[lhc/web/wiklou.git] / languages / LanguageNah.php
1 <?php
2 /** Nahuatl
3 *
4 * @package MediaWiki
5 * @subpackage Language
6 *
7 * @author Rob Church <robchur@gmail.com>
8 *
9 * @copyright Copyright © 2006, Rob Church
10 * @license http://www.gnu.org/copyleft/gpl.html GNU General Public License 2.0 or later
11 */
12
13 require_once( 'LanguageEs.php' );
14
15 if (!$wgCachedMessageArrays) {
16 require_once('MessagesNah.php');
17 }
18
19 # Per conversation with a user in IRC, we inherit from Spanish and work from there
20 # Nahuatl was the language of the Aztecs, and a modern speaker is most likely to
21 # understand Spanish if a Nah translation is not available
22
23 class LanguageNah extends LanguageEs {
24 private $mMessagesNah = null;
25
26 function __construct() {
27 parent::__construct();
28
29 global $wgAllMessagesNah;
30 $this->mMessagesNah =& $wgAllMessagesNah;
31
32 }
33
34 function getFallbackLanguage() {
35 return 'es';
36 }
37
38 function getMessage( $key ) {
39 if( isset( $this->mMessagesNah[$key] ) ) {
40 return $this->mMessagesNah[$key];
41 } else {
42 return parent::getMessage( $key );
43 }
44 }
45
46 function getAllMessages() {
47 return $this->mMessagesNah;
48 }
49
50 }
51
52 ?>