Index: trunk/phase3/includes/parser/Parser.php |
— | — | @@ -3250,7 +3250,7 @@ |
3251 | 3251 | $context->setTitle( $title ); |
3252 | 3252 | $context->setRequest( new FauxRequest( $pageArgs ) ); |
3253 | 3253 | $context->setUser( $this->getUser() ); |
3254 | | - $context->setLang( $this->mOptions->getUserLangObj() ); |
| 3254 | + $context->setLanguage( $this->mOptions->getUserLangObj() ); |
3255 | 3255 | $ret = SpecialPageFactory::capturePath( $title, $context ); |
3256 | 3256 | if ( $ret ) { |
3257 | 3257 | $text = $context->getOutput()->getHTML(); |
Index: trunk/phase3/includes/context/RequestContext.php |
— | — | @@ -165,9 +165,19 @@ |
166 | 166 | /** |
167 | 167 | * Set the Language object |
168 | 168 | * |
| 169 | + * @deprecated 1.19 Use setLanguage instead |
169 | 170 | * @param $l Mixed Language instance or language code |
170 | 171 | */ |
171 | 172 | public function setLang( $l ) { |
| 173 | + $this->setLanguage( $l ); |
| 174 | + } |
| 175 | + |
| 176 | + /** |
| 177 | + * Set the Language object |
| 178 | + * |
| 179 | + * @param $l Mixed Language instance or language code |
| 180 | + */ |
| 181 | + public function setLanguage( $l ) { |
172 | 182 | if ( $l instanceof Language ) { |
173 | 183 | $this->lang = $l; |
174 | 184 | } elseif ( is_string( $l ) ) { |
Index: trunk/phase3/includes/context/DerivativeContext.php |
— | — | @@ -158,9 +158,19 @@ |
159 | 159 | /** |
160 | 160 | * Set the Language object |
161 | 161 | * |
| 162 | + * @deprecated 1.19 Use setLanguage instead |
162 | 163 | * @param $l Mixed Language instance or language code |
163 | 164 | */ |
164 | 165 | public function setLang( $l ) { |
| 166 | + $this->setLanguage( $l ); |
| 167 | + } |
| 168 | + |
| 169 | + /** |
| 170 | + * Set the Language object |
| 171 | + * |
| 172 | + * @param $l Mixed Language instance or language code |
| 173 | + */ |
| 174 | + public function setLanguage( $l ) { |
165 | 175 | if ( $l instanceof Language ) { |
166 | 176 | $this->lang = $l; |
167 | 177 | } elseif ( is_string( $l ) ) { |
Index: trunk/phase3/includes/specials/SpecialUserlogin.php |
— | — | @@ -744,7 +744,7 @@ |
745 | 745 | $code = $request->getVal( 'uselang', $user->getOption( 'language' ) ); |
746 | 746 | $userLang = Language::factory( $code ); |
747 | 747 | $wgLang = $userLang; |
748 | | - $this->getContext()->setLang( $userLang ); |
| 748 | + $this->getContext()->setLanguage( $userLang ); |
749 | 749 | return $this->successfulLogin(); |
750 | 750 | } else { |
751 | 751 | return $this->cookieRedirectCheck( 'login' ); |