Index: trunk/phase3/languages/LanguagePt.php |
— | — | @@ -194,7 +194,7 @@ |
195 | 195 | * Exports $wgMagicWordsPt |
196 | 196 | * @return array |
197 | 197 | */ |
198 | | - function getMagicWords() { |
| 198 | + function &getMagicWords() { |
199 | 199 | global $wgMagicWordsPt; |
200 | 200 | return $wgMagicWordsPt; |
201 | 201 | } |
Index: trunk/phase3/languages/LanguageIs.php |
— | — | @@ -103,7 +103,10 @@ |
104 | 104 | return $this->mMessagesIs; |
105 | 105 | } |
106 | 106 | |
107 | | - function date( $ts, $adj = false, $format = true) { |
| 107 | + /** |
| 108 | + * $timecorrection is for compatibility with Language::date |
| 109 | + */ |
| 110 | + function date( $ts, $adj = false, $format = true, $timecorrection = false ) { |
108 | 111 | if ( $adj ) { $ts = $this->userAdjust( $ts ); } # Adjust based on the timezone setting. |
109 | 112 | $format = $this->dateFormat($format); |
110 | 113 | |
— | — | @@ -123,7 +126,10 @@ |
124 | 127 | |
125 | 128 | } |
126 | 129 | |
127 | | - function time($ts, $adj = false, $format = true) { |
| 130 | + /** |
| 131 | + * $timecorrection is for compatibility with language::time |
| 132 | + */ |
| 133 | + function time($ts, $adj = false, $format = true, $timecorrection = false) { |
128 | 134 | global $wgUser; |
129 | 135 | if ( $adj ) { $ts = $this->userAdjust( $ts ); } # Adjust based on the timezone setting. |
130 | 136 | |
— | — | @@ -137,7 +143,10 @@ |
138 | 144 | |
139 | 145 | } |
140 | 146 | |
141 | | - function timeanddate( $ts, $adj = false, $format = true) { |
| 147 | + /** |
| 148 | + * $timecorrection is for compatibility with Language::date |
| 149 | + */ |
| 150 | + function timeanddate( $ts, $adj = false, $format = true, $timecorrection = false ) { |
142 | 151 | global $wgUser; |
143 | 152 | |
144 | 153 | $format = $this->dateFormat($format); |
Index: trunk/phase3/languages/LanguageBr.php |
— | — | @@ -94,8 +94,10 @@ |
95 | 95 | return $wgSkinNamesBr; |
96 | 96 | } |
97 | 97 | |
98 | | - |
99 | | - function date( $ts, $adj = false ) { |
| 98 | + /** |
| 99 | + * $format and $timecorrection are for compatibility with Language::date |
| 100 | + */ |
| 101 | + function date( $ts, $adj = false, $format = true, $timecorrection = false ) { |
100 | 102 | if ( $adj ) { $ts = $this->userAdjust( $ts ); } |
101 | 103 | |
102 | 104 | $d = (0 + substr( $ts, 6, 2 )) . " " . |
— | — | @@ -104,7 +106,10 @@ |
105 | 107 | return $d; |
106 | 108 | } |
107 | 109 | |
108 | | - function timeanddate( $ts, $adj = false ) { |
| 110 | + /** |
| 111 | + * $format and $timecorrection are for compatibility with Language::date |
| 112 | + */ |
| 113 | + function timeanddate( $ts, $adj = false, $format = true, $timecorrection = false ) { |
109 | 114 | return $this->date( $ts, $adj ) . " da " . $this->time( $ts, $adj ); |
110 | 115 | } |
111 | 116 | |
Index: trunk/phase3/languages/Language.php |
— | — | @@ -1048,8 +1048,8 @@ |
1049 | 1049 | * @param string $wordform3 (optional) |
1050 | 1050 | * @return string |
1051 | 1051 | */ |
1052 | | - function convertPlural( $count, $wordform1, $wordform2, $wordform3) { |
1053 | | - return $count == '1' ? $wordform1 : $wordform2; |
| 1052 | + function convertPlural( $count, $w1, $w2, $w3) { |
| 1053 | + return $count == '1' ? $w1 : $w2; |
1054 | 1054 | } |
1055 | 1055 | |
1056 | 1056 | /** |
Index: trunk/phase3/languages/LanguageSr_ec.php |
— | — | @@ -157,7 +157,7 @@ |
158 | 158 | * Exports $wgMagicWordsSr_ec |
159 | 159 | * @return array |
160 | 160 | */ |
161 | | - function getMagicWords() { |
| 161 | + function &getMagicWords() { |
162 | 162 | global $wgMagicWordsSr_ec; |
163 | 163 | return $wgMagicWordsSr_ec; |
164 | 164 | } |
Index: trunk/phase3/languages/LanguageKo.php |
— | — | @@ -101,7 +101,10 @@ |
102 | 102 | return $this->mMessagesKo; |
103 | 103 | } |
104 | 104 | |
105 | | - function date( $ts, $adj = false ) { |
| 105 | + /** |
| 106 | + * $format and $timecorrection are for compatibility with Language::date |
| 107 | + */ |
| 108 | + function date( $ts, $adj = false, $format = true, $timecorrection = false ) { |
106 | 109 | if ( $adj ) { $ts = $this->userAdjust( $ts ); } |
107 | 110 | |
108 | 111 | $year = (int)substr( $ts, 0, 4 ); |
Index: trunk/phase3/languages/LanguageCy.php |
— | — | @@ -127,7 +127,7 @@ |
128 | 128 | return $wgAllMessagesCy; |
129 | 129 | } |
130 | 130 | |
131 | | - function getMagicWords() { |
| 131 | + function &getMagicWords() { |
132 | 132 | global $wgMagicWordsCy, $wgMagicWordsEn; |
133 | 133 | return $wgMagicWordsCy + $wgMagicWordsEn; |
134 | 134 | } |
Index: trunk/phase3/languages/LanguageHu.php |
— | — | @@ -109,8 +109,10 @@ |
110 | 110 | return "iso8859-2"; |
111 | 111 | } |
112 | 112 | |
113 | | - # localised date and time |
114 | | - function date( $ts, $adj = false ) { |
| 113 | + /** |
| 114 | + * $format and $timecorrection are for compatibility with Language::date |
| 115 | + */ |
| 116 | + function date( $ts, $adj = false, $format = true, $timecorrection = false ) { |
115 | 117 | if ( $adj ) { $ts = $this->userAdjust( $ts ); } |
116 | 118 | |
117 | 119 | $d = substr( $ts, 0, 4 ) . ". " . |
— | — | @@ -119,7 +121,10 @@ |
120 | 122 | return $d; |
121 | 123 | } |
122 | 124 | |
123 | | - function timeanddate( $ts, $adj = false ) { |
| 125 | + /** |
| 126 | + * $format and $timecorrection are for compatibility with Language::date |
| 127 | + */ |
| 128 | + function timeanddate( $ts, $adj = false, $format = true, $timecorrection = false ) { |
124 | 129 | return $this->date( $ts, $adj ) . ", " . $this->time( $ts, $adj ); |
125 | 130 | } |
126 | 131 | |
Index: trunk/phase3/languages/LanguageTt.php |
— | — | @@ -90,8 +90,10 @@ |
91 | 91 | return $wgDateFormatsTt; |
92 | 92 | } |
93 | 93 | |
94 | | - |
95 | | - function date( $ts, $adj = false ) { |
| 94 | + /** |
| 95 | + * $format and $timecorrection are for compatibility with Language::date |
| 96 | + */ |
| 97 | + function date( $ts, $adj = false, $format = true, $timecorrection = false ) { |
96 | 98 | if ( $adj ) { $ts = $this->userAdjust( $ts ); } |
97 | 99 | |
98 | 100 | $d = (0 + substr( $ts, 6, 2 )) . ". " . |
— | — | @@ -100,14 +102,20 @@ |
101 | 103 | return $d; |
102 | 104 | } |
103 | 105 | |
104 | | - function time( $ts, $adj = false ) { |
| 106 | + /** |
| 107 | + * $format and $timecorrection are for compatibility with language::time |
| 108 | + */ |
| 109 | + function time($ts, $adj = false, $format = true, $timecorrection = false) { |
105 | 110 | if ( $adj ) { $ts = $this->userAdjust( $ts ); } |
106 | 111 | |
107 | 112 | $t = substr( $ts, 8, 2 ) . ":" . substr( $ts, 10, 2 ); |
108 | 113 | return $t; |
109 | 114 | } |
110 | 115 | |
111 | | - function timeanddate( $ts, $adj = false ) { |
| 116 | + /** |
| 117 | + * $format and $timecorrection are for compatibility with Language::date |
| 118 | + */ |
| 119 | + function timeanddate( $ts, $adj = false, $format = true, $timecorrection = false ) { |
112 | 120 | return $this->date( $ts, $adj ) . ", " . $this->time( $ts, $adj ); |
113 | 121 | } |
114 | 122 | |
Index: trunk/phase3/languages/LanguageAr.php |
— | — | @@ -147,7 +147,7 @@ |
148 | 148 | return 'windows-1256'; |
149 | 149 | } |
150 | 150 | |
151 | | - function getMagicWords() { |
| 151 | + function &getMagicWords() { |
152 | 152 | global $wgMagicWordsAr; |
153 | 153 | return $wgMagicWordsAr; |
154 | 154 | } |
Index: trunk/phase3/languages/LanguageBg.php |
— | — | @@ -167,7 +167,7 @@ |
168 | 168 | * Exports $wgMagicWordsBg |
169 | 169 | * @return array |
170 | 170 | */ |
171 | | - function getMagicWords() { |
| 171 | + function &getMagicWords() { |
172 | 172 | global $wgMagicWordsBg; |
173 | 173 | return $wgMagicWordsBg; |
174 | 174 | } |
Index: trunk/phase3/languages/LanguageNn.php |
— | — | @@ -171,7 +171,10 @@ |
172 | 172 | } |
173 | 173 | |
174 | 174 | |
175 | | - function time($ts, $adj = false, $format = true) { |
| 175 | + /** |
| 176 | + * $timecorrection is for compatibility with language::time |
| 177 | + */ |
| 178 | + function time($ts, $adj = false, $format = true, $timecorrection = false) { |
176 | 179 | if ( $adj ) { $ts = $this->userAdjust( $ts ); } # Adjust based on the timezone setting. |
177 | 180 | |
178 | 181 | $format = $this->dateFormat($format); |
— | — | @@ -184,7 +187,10 @@ |
185 | 188 | |
186 | 189 | } |
187 | 190 | |
188 | | - function date( $ts, $adj = false, $format = true) { |
| 191 | + /** |
| 192 | + * $timecorrection is for compatibility with Language::date |
| 193 | + */ |
| 194 | + function date( $ts, $adj = false, $format = true, $timecorrection = false ) { |
189 | 195 | global $wgUser; |
190 | 196 | if ( $adj ) { $ts = $this->userAdjust( $ts ); } # Adjust based on the timezone setting. |
191 | 197 | $format = $this->dateFormat($format); |
— | — | @@ -205,7 +211,10 @@ |
206 | 212 | |
207 | 213 | } |
208 | 214 | |
209 | | - function timeanddate( $ts, $adj = false, $format = true) { |
| 215 | + /** |
| 216 | + * $format and $timecorrection are for compatibility with Language::date |
| 217 | + */ |
| 218 | + function timeanddate( $ts, $adj = false, $format = true, $timecorrection = false ) { |
210 | 219 | global $wgUser; |
211 | 220 | |
212 | 221 | $format = $this->dateFormat($format); |
Index: trunk/phase3/languages/LanguageRu.php |
— | — | @@ -154,7 +154,7 @@ |
155 | 155 | //only for quotation mark |
156 | 156 | function linkPrefixExtension() { return true; } |
157 | 157 | |
158 | | - function getMagicWords() { |
| 158 | + function &getMagicWords() { |
159 | 159 | global $wgMagicWordsRu; |
160 | 160 | return $wgMagicWordsRu; |
161 | 161 | } |
Index: trunk/phase3/languages/LanguageZh_cn.php |
— | — | @@ -95,7 +95,10 @@ |
96 | 96 | return false; |
97 | 97 | } |
98 | 98 | |
99 | | - function date( $ts, $adj = false ) { |
| 99 | + /** |
| 100 | + * $format and $timecorrection are for compatibility with Language::date |
| 101 | + */ |
| 102 | + function date( $ts, $adj = false, $format = true, $timecorrection = false ) { |
100 | 103 | if ( $adj ) { $ts = $this->userAdjust( $ts ); } |
101 | 104 | |
102 | 105 | $d = substr( $ts, 0, 4 ) . "年" . |
— | — | @@ -104,7 +107,10 @@ |
105 | 108 | return $d; |
106 | 109 | } |
107 | 110 | |
108 | | - function timeanddate( $ts, $adj = false ) { |
| 111 | + /** |
| 112 | + * $format and $timecorrection are for compatibility with Language::date |
| 113 | + */ |
| 114 | + function timeanddate( $ts, $adj = false, $format = true, $timecorrection = false ) { |
109 | 115 | return $this->time( $ts, $adj ) . " " . $this->date( $ts, $adj ); |
110 | 116 | } |
111 | 117 | |
Index: trunk/phase3/languages/LanguageSr_el.php |
— | — | @@ -157,7 +157,7 @@ |
158 | 158 | * Exports $wgMagicWordsSr_el |
159 | 159 | * @return array |
160 | 160 | */ |
161 | | - function getMagicWords() { |
| 161 | + function &getMagicWords() { |
162 | 162 | global $wgMagicWordsSr_el; |
163 | 163 | return $wgMagicWordsSr_el; |
164 | 164 | } |
Index: trunk/phase3/languages/LanguageSr.php |
— | — | @@ -66,7 +66,7 @@ |
67 | 67 | /* rules should be defined as -{ekavian | iyekavian-} -or- |
68 | 68 | -{code:text | code:text | ...}- |
69 | 69 | */ |
70 | | - function parseManualRule($rule, $flags) { |
| 70 | + function parseManualRule($rule, $flags=array()) { |
71 | 71 | |
72 | 72 | $echoices = preg_split("/(<[^>]+>)/",$rule,-1,PREG_SPLIT_DELIM_CAPTURE); |
73 | 73 | $choices = array(); |
Index: trunk/phase3/languages/LanguageDa.php |
— | — | @@ -80,7 +80,10 @@ |
81 | 81 | return $wgDateFormatsDa; |
82 | 82 | } |
83 | 83 | |
84 | | - function date( $ts, $adj = false ) { |
| 84 | + /** |
| 85 | + * $format and $timecorrection are for compatibility with Language::date |
| 86 | + */ |
| 87 | + function date( $ts, $adj = false, $format = true, $timecorrection = false ) { |
85 | 88 | if ( $adj ) { $ts = $this->userAdjust( $ts ); } |
86 | 89 | |
87 | 90 | $d = (0 + substr( $ts, 6, 2 )) . ". " . |
— | — | @@ -89,7 +92,10 @@ |
90 | 93 | return $d; |
91 | 94 | } |
92 | 95 | |
93 | | - function timeanddate( $ts, $adj = false ) { |
| 96 | + /** |
| 97 | + * $format and $timecorrection are for compatibility with Language::date |
| 98 | + */ |
| 99 | + function timeanddate( $ts, $adj = false, $format = true, $timecorrection = false ) { |
94 | 100 | return $this->date( $ts, $adj ) . " kl. " . $this->time( $ts, $adj ); |
95 | 101 | } |
96 | 102 | |