Index: trunk/extensions/Translate/groups/Mantis.php |
— | — | @@ -1,127 +0,0 @@ |
2 | | -<?php |
3 | | -/** |
4 | | - * Support MantisBT: http://www.mantisbt.org. |
5 | | - * |
6 | | - * @file |
7 | | - * @ingroup Extensions |
8 | | - * |
9 | | - * @copyright Copyright © 2008-2009, Translatewiki.net developers |
10 | | - * @license http://www.gnu.org/copyleft/gpl.html GNU General Public License 2.0 or later |
11 | | - */ |
12 | | - |
13 | | -class MantisMessageGroup extends MessageGroupOld { |
14 | | - protected $label = 'MantisBT (web-based bugtracking system)'; |
15 | | - protected $id = 'out-mantis'; |
16 | | - protected $type = 'mantis'; |
17 | | - |
18 | | - protected $fileDir = '__BUG__'; |
19 | | - |
20 | | - public function getPath() { return $this->fileDir; } |
21 | | - public function setPath( $value ) { $this->fileDir = $value; } |
22 | | - |
23 | | - protected $codeMap = array( |
24 | | - 'af' => 'afrikaans', |
25 | | - 'am' => 'amharic', |
26 | | - 'ar' => 'arabic', |
27 | | - 'arz' => 'arabicegyptianspoken', |
28 | | - 'bg' => 'bulgarian', |
29 | | - 'br' => 'breton', |
30 | | - 'ca' => 'catalan', |
31 | | - 'cs' => 'czech', |
32 | | - 'da' => 'danish', |
33 | | - 'de' => 'german', |
34 | | - 'el' => 'greek', |
35 | | - 'en' => 'english', |
36 | | - 'es' => 'spanish', |
37 | | - 'et' => 'estonian', |
38 | | - 'fi' => 'finnish', |
39 | | - 'fr' => 'french', |
40 | | - 'gl' => 'galician', |
41 | | - 'gsw' => 'swissgerman', |
42 | | - 'he' => 'hebrew', |
43 | | - 'hr' => 'croatian', |
44 | | - 'hu' => 'hungarian', |
45 | | - 'is' => 'icelandic', |
46 | | - 'it' => 'italian', |
47 | | - 'ja' => 'japanese', |
48 | | - 'ksh' => 'ripoarisch', |
49 | | - 'ko' => 'korean', |
50 | | - 'lt' => 'lithuanian', |
51 | | - 'lv' => 'latvian', |
52 | | - 'mk' => 'macedonian', |
53 | | - 'nl' => 'dutch', |
54 | | - 'nn' => 'norwegian_nynorsk', |
55 | | - 'no' => 'norwegian_bokmal', |
56 | | - 'oc' => 'occitan', |
57 | | - 'pl' => 'polish', |
58 | | - 'pt' => 'portuguese_standard', |
59 | | - 'pt-br' => 'portuguese_brazil', |
60 | | - 'ro' => 'romanian', |
61 | | - 'ru' => 'russian', |
62 | | - 'sk' => 'slovak', |
63 | | - 'sl' => 'slovene', |
64 | | - 'sr-ec' => 'serbian', |
65 | | - 'sv' => 'swedish', |
66 | | - 'tl' => 'tagalog', |
67 | | - 'tr' => 'turkish', |
68 | | - 'uk' => 'ukrainian', |
69 | | - 'ur' => 'urdu', |
70 | | - 'vo' => 'volapuk', |
71 | | - 'zh-hans' => 'chinese_simplified', |
72 | | - 'zh-hant' => 'chinese_traditional', |
73 | | - ); |
74 | | - |
75 | | - protected $optional = array( |
76 | | - 's_sponsorship_process_url', 's_charset', 's_p', |
77 | | - 's_priority_abbreviation', 's_attachment_alt', 's_phpmailer_language', |
78 | | - 's_word_separator', 's_directionality', 's_label' |
79 | | - ); |
80 | | - |
81 | | - public $header = '<?php |
82 | | -/** MantisBT - a php based bugtracking system |
83 | | - * |
84 | | - * Copyright (C) 2000 - 2002 Kenzaburo Ito - kenito@300baud.org |
85 | | - * Copyright (C) 2002 - 2010 MantisBT Team - mantisbt-dev@lists.sourceforge.net |
86 | | - * |
87 | | - * MantisBT is free software: you can redistribute it and/or modify |
88 | | - * it under the terms of the GNU General Public License as published by |
89 | | - * the Free Software Foundation, either version 2 of the License, or |
90 | | - * (at your option) any later version. |
91 | | - * |
92 | | - * MantisBT is distributed in the hope that it will be useful, |
93 | | - * but WITHOUT ANY WARRANTY; without even the implied warranty of |
94 | | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
95 | | - * GNU General Public License for more details. |
96 | | - * |
97 | | - * You should have received a copy of the GNU General Public License |
98 | | - * along with MantisBT. If not, see <http://www.gnu.org/licenses/>. |
99 | | - */'; |
100 | | - |
101 | | - public function getMessageFile( $code ) { |
102 | | - if ( isset( $this->codeMap[$code] ) ) { |
103 | | - $code = $this->codeMap[$code]; |
104 | | - } |
105 | | - return "strings_$code.txt"; |
106 | | - } |
107 | | - |
108 | | - protected function getFileLocation( $code ) { |
109 | | - return $this->fileDir . '/' . $this->getMessageFile( $code ); |
110 | | - } |
111 | | - |
112 | | - public function getReader( $code ) { |
113 | | - return new PhpVariablesFormatReader( $this->getFileLocation( $code ) ); |
114 | | - } |
115 | | - |
116 | | - public function getWriter() { |
117 | | - return new PhpVariablesFormatWriter( $this ); |
118 | | - } |
119 | | - |
120 | | - public function getChecker() { |
121 | | - $checker = new MessageChecker( $this ); |
122 | | - $checker->setChecks( array( |
123 | | - array( $checker, 'printfCheck' ), |
124 | | - array( $checker, 'braceBalanceCheck' ), |
125 | | - ) ); |
126 | | - return $checker; |
127 | | - } |
128 | | -} |
Index: trunk/extensions/Translate/groups/MantisBT/MantisBT.yml |
— | — | @@ -86,10 +86,25 @@ |
87 | 87 | |
88 | 88 | --- |
89 | 89 | BASIC: |
90 | | - id: out-mantis |
| 90 | + id: out-mantis-0-all |
| 91 | + label: All MantisBT messages |
| 92 | + display: out/mantis |
| 93 | + description: "{{int:bw-desc-mantisbt}}" |
| 94 | + meta: yes |
| 95 | + class: AggregateMessageGroup |
| 96 | + |
| 97 | +GROUPS: |
| 98 | + - out-mantis |
| 99 | + - out-mantis-mantiscoreformatting |
| 100 | + - out-mantis-mantisgraph |
| 101 | + - out-mantis-xmlimportexport |
| 102 | + |
| 103 | +--- |
| 104 | +BASIC: |
| 105 | + id: out-mantis-core |
91 | 106 | label: MantisBT (web-based bugtracking system) |
92 | 107 | description: "{{int:bw-desc-mantisbt}}" |
93 | | - display: out/mantis/ |
| 108 | + display: out/mantis/core |
94 | 109 | |
95 | 110 | FILES: |
96 | 111 | sourcePattern: %GROUPROOT%/mantisbt/lang/strings_%CODE%.txt |
Index: trunk/extensions/Translate/_autoload.php |
— | — | @@ -96,7 +96,6 @@ |
97 | 97 | $wgAutoloadClasses['PremadeMediawikiExtensionGroups'] = $dir . 'groups/MediaWikiExtensions.php'; |
98 | 98 | $wgAutoloadClasses['PremadeWikiaExtensionGroups'] = $dir . 'groups/Wikia/WikiaExtensions.php'; |
99 | 99 | $wgAutoloadClasses['CommonistMessageGroup'] = $dir . 'groups/Commonist.php'; |
100 | | -$wgAutoloadClasses['MantisMessageGroup'] = $dir . 'groups/Mantis.php'; |
101 | 100 | $wgAutoloadClasses['NoccMessageGroup'] = $dir . 'groups/Nocc.php'; |
102 | 101 | $wgAutoloadClasses['OpenLayersMessageGroup'] = $dir . 'groups/OpenLayers.php'; |
103 | 102 | $wgAutoloadClasses['WikiblameMessageGroup'] = $dir . 'groups/Wikiblame.php'; |