| Index: trunk/phase3/RELEASE-NOTES-1.19 |
| — | — | @@ -97,6 +97,7 @@ |
| 98 | 98 | and adding paths to the PathRouter. |
| 99 | 99 | * (bug 32666) Special:ActiveUsers now allows a subpage to be used as the |
| 100 | 100 | username (eg. Special:ActiveUsers/Username) |
| | 101 | +* New JavaScript variable wgPageContentLanguage |
| 101 | 102 | |
| 102 | 103 | === Bug fixes in 1.19 === |
| 103 | 104 | * $wgUploadNavigationUrl should be used for file redlinks if. |
| — | — | @@ -163,6 +164,9 @@ |
| 164 | 165 | * (bug 29475) Remove "trackback" feature entirely from core |
| 165 | 166 | * (bug 32665) Special:BlockList prefills the username in the input field if |
| 166 | 167 | using the Special:BlockList\username URL |
| | 168 | +* (bug 27721) Make JavaScript variables wgSeparatorTransformTable and |
| | 169 | + wgDigitTransformTable depend on page content language so the sort script |
| | 170 | + sorts correctly more often |
| 167 | 171 | |
| 168 | 172 | === API changes in 1.19 === |
| 169 | 173 | * (bug 19838) siprop=interwikimap can now use the interwiki cache. |
| Index: trunk/phase3/includes/OutputPage.php |
| — | — | @@ -2727,6 +2727,22 @@ |
| 2728 | 2728 | $canonicalName = false; # bug 21115 |
| 2729 | 2729 | } |
| 2730 | 2730 | |
| | 2731 | + $lang = $title->getPageLanguage(); |
| | 2732 | + |
| | 2733 | + // Pre-process information |
| | 2734 | + $separatorTransTable = $lang->separatorTransformTable(); |
| | 2735 | + $separatorTransTable = $separatorTransTable ? $separatorTransTable : array(); |
| | 2736 | + $compactSeparatorTransTable = array( |
| | 2737 | + implode( "\t", array_keys( $separatorTransTable ) ), |
| | 2738 | + implode( "\t", $separatorTransTable ), |
| | 2739 | + ); |
| | 2740 | + $digitTransTable = $lang->digitTransformTable(); |
| | 2741 | + $digitTransTable = $digitTransTable ? $digitTransTable : array(); |
| | 2742 | + $compactDigitTransTable = array( |
| | 2743 | + implode( "\t", array_keys( $digitTransTable ) ), |
| | 2744 | + implode( "\t", $digitTransTable ), |
| | 2745 | + ); |
| | 2746 | + |
| 2731 | 2747 | $vars = array( |
| 2732 | 2748 | 'wgCanonicalNamespace' => $nsname, |
| 2733 | 2749 | 'wgCanonicalSpecialPageName' => $canonicalName, |
| — | — | @@ -2741,8 +2757,10 @@ |
| 2742 | 2758 | 'wgUserGroups' => $this->getUser()->getEffectiveGroups(), |
| 2743 | 2759 | 'wgCategories' => $this->getCategories(), |
| 2744 | 2760 | 'wgBreakFrames' => $this->getFrameOptions() == 'DENY', |
| | 2761 | + 'wgPageContentLanguage' => $lang->getCode(), |
| | 2762 | + 'wgSeparatorTransformTable' => $compactSeparatorTransTable, |
| | 2763 | + 'wgDigitTransformTable' => $compactDigitTransTable, |
| 2745 | 2764 | ); |
| 2746 | | - $lang = $this->getTitle()->getPageLanguage(); |
| 2747 | 2765 | if ( $lang->hasVariants() ) { |
| 2748 | 2766 | $vars['wgUserVariant'] = $lang->getPreferredVariant(); |
| 2749 | 2767 | } |
| Index: trunk/phase3/includes/resourceloader/ResourceLoaderStartUpModule.php |
| — | — | @@ -40,19 +40,6 @@ |
| 41 | 41 | $wgSitename, $wgFileExtensions, $wgExtensionAssetsPath, |
| 42 | 42 | $wgCookiePrefix, $wgResourceLoaderMaxQueryLength, $wgLegacyJavaScriptGlobals; |
| 43 | 43 | |
| 44 | | - // Pre-process information |
| 45 | | - $separatorTransTable = $wgContLang->separatorTransformTable(); |
| 46 | | - $separatorTransTable = $separatorTransTable ? $separatorTransTable : array(); |
| 47 | | - $compactSeparatorTransTable = array( |
| 48 | | - implode( "\t", array_keys( $separatorTransTable ) ), |
| 49 | | - implode( "\t", $separatorTransTable ), |
| 50 | | - ); |
| 51 | | - $digitTransTable = $wgContLang->digitTransformTable(); |
| 52 | | - $digitTransTable = $digitTransTable ? $digitTransTable : array(); |
| 53 | | - $compactDigitTransTable = array( |
| 54 | | - implode( "\t", array_keys( $digitTransTable ) ), |
| 55 | | - implode( "\t", $digitTransTable ), |
| 56 | | - ); |
| 57 | 44 | $mainPage = Title::newMainPage(); |
| 58 | 45 | |
| 59 | 46 | /** |
| — | — | @@ -91,8 +78,6 @@ |
| 92 | 79 | 'wgDefaultDateFormat' => $wgContLang->getDefaultDateFormat(), |
| 93 | 80 | 'wgMonthNames' => $wgContLang->getMonthNamesArray(), |
| 94 | 81 | 'wgMonthNamesShort' => $wgContLang->getMonthAbbreviationsArray(), |
| 95 | | - 'wgSeparatorTransformTable' => $compactSeparatorTransTable, |
| 96 | | - 'wgDigitTransformTable' => $compactDigitTransTable, |
| 97 | 82 | 'wgMainPageTitle' => $mainPage ? $mainPage->getPrefixedText() : null, |
| 98 | 83 | 'wgFormattedNamespaces' => $wgContLang->getFormattedNamespaces(), |
| 99 | 84 | 'wgNamespaceIds' => $namespaceIds, |