Index: trunk/extensions/CategoryBrowser/CategoryBrowserView.php |
— | — | @@ -146,7 +146,8 @@ |
147 | 147 | $result = ''; |
148 | 148 | if ( !empty( $pager_row->cl_sortkey ) && |
149 | 149 | $title_obj->getText() != $pager_row->cl_sortkey ) { |
150 | | - $cv = new CategoryViewer( $title_obj ); |
| 150 | + // TODO: Get better context |
| 151 | + $cv = new CategoryViewer( $title_obj, RequestContext::getMain() ); |
151 | 152 | $this->sortkey_hint = '(' . $cv->getSubcategorySortChar( $title_obj, $pager_row->cl_sortkey ) . ')'; |
152 | 153 | $result = CB_XML::toText( $this->sortkey_hint_tpl ); |
153 | 154 | } |
Index: trunk/extensions/CategoryMultisort/CategoryMultisort.hooks.php |
— | — | @@ -378,7 +378,10 @@ |
379 | 379 | |
380 | 380 | $from = $wgRequest->getVal( 'from' ); |
381 | 381 | $until = $wgRequest->getVal( 'until' ); |
382 | | - $viewer = new CategoryMultisortViewer( $title, $skn, $from, $until ); |
| 382 | + $viewer = new CategoryMultisortViewer( |
| 383 | + $title, $categoryArticle->getContext(), $skn, |
| 384 | + $from, $until |
| 385 | + ); |
383 | 386 | $wgOut->addHTML( $viewer->getHTML() ); |
384 | 387 | |
385 | 388 | return false; |
Index: trunk/extensions/CategoryMultisort/CategoryMultisort.class.php |
— | — | @@ -6,9 +6,9 @@ |
7 | 7 | |
8 | 8 | class CategoryMultisortViewer extends CategoryViewer { |
9 | 9 | |
10 | | - function __construct( $title, $skn, $from = '', $until = '' ) { |
| 10 | + function __construct( $title, IContextSource $context, $skn, $from = '', $until = '' ) { |
11 | 11 | global $wgCategoryMultisortSortkeySettings; |
12 | | - parent::__construct( $title, $from, $until ); |
| 12 | + parent::__construct( $title, $context, $from, $until ); |
13 | 13 | $this->sortkeyName = $skn; |
14 | 14 | $this->sortkeySettings = $wgCategoryMultisortSortkeySettings[$skn]; |
15 | 15 | } |