http://www.mediawiki.org/wiki/Special:Code/MediaWiki/97635
Revision: 97635
Author: catrope
Date: 2011-09-20 15:54:15 +0000 (Tue, 20 Sep 2011)
Log Message:
-----------
1.18wmf1: MFT r96760, r96765, r97551, r97552, r97622
Modified Paths:
--------------
branches/wmf/1.18wmf1/RELEASE-NOTES-1.18
branches/wmf/1.18wmf1/includes/AutoLoader.php
branches/wmf/1.18wmf1/includes/Collation.php
branches/wmf/1.18wmf1/includes/DefaultSettings.php
branches/wmf/1.18wmf1/includes/OutputPage.php
branches/wmf/1.18wmf1/maintenance/deleteBatch.php
branches/wmf/1.18wmf1/skins/CologneBlue.php
branches/wmf/1.18wmf1/skins/Simple.php
branches/wmf/1.18wmf1/skins/Standard.php
branches/wmf/1.18wmf1/skins/common/shared.css
Property Changed:
----------------
branches/wmf/1.18wmf1/includes/AutoLoader.php
branches/wmf/1.18wmf1/includes/OutputPage.php
Modified: branches/wmf/1.18wmf1/RELEASE-NOTES-1.18
===================================================================
--- branches/wmf/1.18wmf1/RELEASE-NOTES-1.18 2011-09-20 15:33:17 UTC (rev
97634)
+++ branches/wmf/1.18wmf1/RELEASE-NOTES-1.18 2011-09-20 15:54:15 UTC (rev
97635)
@@ -210,6 +210,7 @@
them (i.e. with array_keys) to get a list of all preferences, then
$wgDefaultUserOptions should no longer be used as it will contain those set
via
User:getDefaultOptions().
+* (bug 30722) Add a new collation that sorts categories in ascii sort order.
=== Bug fixes in 1.18 ===
* mw.util.getScript has been implemented (like wfScript in GlobalFunctions.php)
Modified: branches/wmf/1.18wmf1/includes/AutoLoader.php
===================================================================
--- branches/wmf/1.18wmf1/includes/AutoLoader.php 2011-09-20 15:33:17 UTC
(rev 97634)
+++ branches/wmf/1.18wmf1/includes/AutoLoader.php 2011-09-20 15:54:15 UTC
(rev 97635)
@@ -116,6 +116,7 @@
'HttpRequest' => 'includes/HttpFunctions.old.php',
'IContextSource' => 'includes/RequestContext.php',
'IcuCollation' => 'includes/Collation.php',
+ 'IdentityCollation' => 'includes/Collation.php',
'ImageGallery' => 'includes/ImageGallery.php',
'ImageHistoryList' => 'includes/ImagePage.php',
'ImageHistoryPseudoPager' => 'includes/ImagePage.php',
Property changes on: branches/wmf/1.18wmf1/includes/AutoLoader.php
___________________________________________________________________
Modified: svn:mergeinfo
- /branches/REL1_15/phase3/includes/AutoLoader.php:51646
/branches/REL1_17/phase3/includes/AutoLoader.php:81448
/branches/new-installer/phase3/includes/AutoLoader.php:43664-66004
/branches/sqlite/includes/AutoLoader.php:58211-58321
/branches/uploadwizard/phase3/includes/AutoLoader.php:73550-75905
/branches/wmf-deployment/includes/AutoLoader.php:53381
/trunk/phase3/includes/AutoLoader.php:92580,92713,92765,92884,92886-92887,92894,92898,92907,92932,93149,93151,93233-93234,93258,93266,93382-93383,93516-93518,93818-93822,93847,93858,93891,93935-93936,94068,94155,94235-94236,94346,94372,94422,94425,94444,94448,94456,94498,94601,94728,94825,94862,94995-94997,95171,95409,95436,95458,95467,95470,95475,95493,95521,95525,95540
+ /branches/REL1_15/phase3/includes/AutoLoader.php:51646
/branches/REL1_17/phase3/includes/AutoLoader.php:81448
/branches/new-installer/phase3/includes/AutoLoader.php:43664-66004
/branches/sqlite/includes/AutoLoader.php:58211-58321
/branches/uploadwizard/phase3/includes/AutoLoader.php:73550-75905
/branches/wmf-deployment/includes/AutoLoader.php:53381
/trunk/phase3/includes/AutoLoader.php:92580,92713,92765,92884,92886-92887,92894,92898,92907,92932,93149,93151,93233-93234,93258,93266,93382-93383,93516-93518,93818-93822,93847,93858,93891,93935-93936,94068,94155,94235-94236,94346,94372,94422,94425,94444,94448,94456,94498,94601,94728,94825,94862,94995-94997,95171,95409,95436,95458,95467,95470,95475,95493,95521,95525,95540,96760,96765,97551-97552,97622
Modified: branches/wmf/1.18wmf1/includes/Collation.php
===================================================================
--- branches/wmf/1.18wmf1/includes/Collation.php 2011-09-20 15:33:17 UTC
(rev 97634)
+++ branches/wmf/1.18wmf1/includes/Collation.php 2011-09-20 15:54:15 UTC
(rev 97635)
@@ -23,6 +23,8 @@
switch( $collationName ) {
case 'uppercase':
return new UppercaseCollation;
+ case 'identity':
+ return new IdentityCollation;
case 'uca-default':
return new IcuCollation( 'root' );
default:
@@ -99,6 +101,30 @@
}
}
+/**
+ * Collation class that's essentially a no-op.
+ *
+ * Does sorting based on binary value of the string.
+ * Like how things were pre 1.17.
+ */
+class IdentityCollation extends Collation {
+
+ function getSortKey( $string ) {
+ return $string;
+ }
+
+ function getFirstLetter( $string ) {
+ global $wgContLang;
+ // Copied from UppercaseCollation.
+ // I'm kind of unclear on when this could happen...
+ if ( $string[0] == "\0" ) {
+ $string = substr( $string, 1 );
+ }
+ return $wgContLang->firstChar( $string );
+ }
+}
+
+
class IcuCollation extends Collation {
var $primaryCollator, $mainCollator, $locale;
var $firstLetterData;
Modified: branches/wmf/1.18wmf1/includes/DefaultSettings.php
===================================================================
--- branches/wmf/1.18wmf1/includes/DefaultSettings.php 2011-09-20 15:33:17 UTC
(rev 97634)
+++ branches/wmf/1.18wmf1/includes/DefaultSettings.php 2011-09-20 15:54:15 UTC
(rev 97635)
@@ -4798,6 +4798,8 @@
*
* - uppercase: Converts the category name to upper case, and sorts by that.
*
+ * - identity: Does no conversion. Sorts by binary value of the string.
+ *
* - uca-default: Provides access to the Unicode Collation Algorithm with
* the default element table. This is a compromise collation which sorts
* all languages in a mediocre way. However, it is better than "uppercase".
@@ -4811,7 +4813,7 @@
* the sort keys in the database.
*
* Extensions can define there own collations by subclassing Collation
- * and using the class name as the value of this variable.
+ * and using the Collation::factory hook.
*/
$wgCategoryCollation = 'uppercase';
Modified: branches/wmf/1.18wmf1/includes/OutputPage.php
===================================================================
--- branches/wmf/1.18wmf1/includes/OutputPage.php 2011-09-20 15:33:17 UTC
(rev 97634)
+++ branches/wmf/1.18wmf1/includes/OutputPage.php 2011-09-20 15:54:15 UTC
(rev 97635)
@@ -2902,10 +2902,10 @@
/**
* Adds inline CSS styles
* @param $style_css Mixed: inline CSS
- * @param $flip Boolean: Whether to flip the CSS if needed
+ * @param $flip False or String: Set to 'flip' to flip the CSS if needed
*/
public function addInlineStyle( $style_css, $flip = false ) {
- if( $flip && $this->getLang()->isRTL() ) {
+ if( $flip === 'flip' && $this->getLang()->isRTL() ) {
# If wanted, and the interface is right-to-left, flip
the CSS
$style_css = CSSJanus::transform( $style_css, true,
false );
}
Property changes on: branches/wmf/1.18wmf1/includes/OutputPage.php
___________________________________________________________________
Modified: svn:mergeinfo
- /branches/REL1_15/phase3/includes/OutputPage.php:51646
/branches/REL1_17/phase3/includes/OutputPage.php:81445
/branches/resourceloader/phase3/includes/OutputPage.php:68366-69676,69678-70682,70684-71999,72001-72255,72257-72305,72307-72342
/branches/wmf-deployment/includes/OutputPage.php:53381,57468
/trunk/phase3/includes/OutputPage.php:92551-92552,92560,92563-92564,92568,92570,92573-92574,92576,92580-92581,92713,92765,92884,92886-92887,92894,92898,92907,92932,93149,93151,93233-93234,93258,93266,93288,93382-93383,93516-93518,93557,93818-93822,93847,93858,93891,93935-93936,94068,94155,94212,94235-94236,94277,94346,94372,94422,94425,94444,94448,94456,94498,94517,94601,94728,94737-94738,94825,94862,94990,94995-94997,95000-95002,95006-95007,95010-95011,95023,95072-95073,95171,95327,95409,95422,95426,95436,95458,95467,95470,95475,95493,95521,95525,95540,95601,95655,95894,96227,96261,96263,96384,96386,96393,96405,96427,96460,96472,97159
+ /branches/REL1_15/phase3/includes/OutputPage.php:51646
/branches/REL1_17/phase3/includes/OutputPage.php:81445
/branches/resourceloader/phase3/includes/OutputPage.php:68366-69676,69678-70682,70684-71999,72001-72255,72257-72305,72307-72342
/branches/wmf-deployment/includes/OutputPage.php:53381,57468
/trunk/phase3/includes/OutputPage.php:92551-92552,92560,92563-92564,92568,92570,92573-92574,92576,92580-92581,92713,92765,92884,92886-92887,92894,92898,92907,92932,93149,93151,93233-93234,93258,93266,93288,93382-93383,93516-93518,93557,93818-93822,93847,93858,93891,93935-93936,94068,94155,94212,94235-94236,94277,94346,94372,94422,94425,94444,94448,94456,94498,94517,94601,94728,94737-94738,94825,94862,94990,94995-94997,95000-95002,95006-95007,95010-95011,95023,95072-95073,95171,95327,95409,95422,95426,95436,95458,95467,95470,95475,95493,95521,95525,95540,95601,95655,95894,96227,96261,96263,96384,96386,96393,96405,96427,96460,96472,96760,96765,97159,97551-97552,97622
Modified: branches/wmf/1.18wmf1/maintenance/deleteBatch.php
===================================================================
--- branches/wmf/1.18wmf1/maintenance/deleteBatch.php 2011-09-20 15:33:17 UTC
(rev 97634)
+++ branches/wmf/1.18wmf1/maintenance/deleteBatch.php 2011-09-20 15:54:15 UTC
(rev 97635)
@@ -87,8 +87,10 @@
if ( $page->getNamespace() == NS_FILE ) {
$art = new ImagePage( $page );
$img = wfFindFile( $art->mTitle );
- if ( !$img || !$img->delete( $reason ) ) {
- $this->output( "FAILED to delete image
file... " );
+ if ( !$img
+ || !$img->isLocal()
+ || !$img->delete( $reason ) ) {
+ $this->output( " FAILED to delete image
file... " );
}
} else {
$art = new Article( $page );
@@ -96,7 +98,7 @@
$success = $art->doDeleteArticle( $reason );
$dbw->commit();
if ( $success ) {
- $this->output( "\n" );
+ $this->output( " Deleted!\n" );
} else {
$this->output( " FAILED to delete article\n" );
}
Modified: branches/wmf/1.18wmf1/skins/CologneBlue.php
===================================================================
--- branches/wmf/1.18wmf1/skins/CologneBlue.php 2011-09-20 15:33:17 UTC (rev
97634)
+++ branches/wmf/1.18wmf1/skins/CologneBlue.php 2011-09-20 15:54:15 UTC (rev
97635)
@@ -44,7 +44,7 @@
$rules[] = "/* @noflip */body>#quickbar { position:
fixed; right: 4px; top: 4px; overflow: auto; bottom:4px;}"; # Hides from IE
}
$style = implode( "\n", $rules );
- $out->addInlineStyle( $style, /* flip css if RTL */true );
+ $out->addInlineStyle( $style, 'flip' );
}
}
Modified: branches/wmf/1.18wmf1/skins/Simple.php
===================================================================
--- branches/wmf/1.18wmf1/skins/Simple.php 2011-09-20 15:33:17 UTC (rev
97634)
+++ branches/wmf/1.18wmf1/skins/Simple.php 2011-09-20 15:54:15 UTC (rev
97635)
@@ -42,7 +42,7 @@
$rules[] = "a.stub:after { $underline; }";
}
$style = implode( "\n", $rules );
- $out->addInlineStyle( $style, /* flip css if RTL */true );
+ $out->addInlineStyle( $style, 'flip' );
}
}
Modified: branches/wmf/1.18wmf1/skins/Standard.php
===================================================================
--- branches/wmf/1.18wmf1/skins/Standard.php 2011-09-20 15:33:17 UTC (rev
97634)
+++ branches/wmf/1.18wmf1/skins/Standard.php 2011-09-20 15:54:15 UTC (rev
97635)
@@ -27,20 +27,20 @@
if ( 2 == $qb ) { # Right
$rules[] = "/* @noflip */#quickbar { position:
absolute; top: 4px; right: 4px; border-left: 2px solid #000000; }";
- $rules[] = "/* @noflip */#article, /* @noflip
*/#mw-data-after-content { margin-left: 4px; margin-right: 152px; }";
+ $rules[] = "/* @noflip */#article,
#mw-data-after-content { margin-left: 4px; margin-right: 152px; }";
} elseif ( 1 == $qb || 3 == $qb ) {
$rules[] = "/* @noflip */#quickbar { position:
absolute; top: 4px; left: 4px; border-right: 1px solid gray; }";
- $rules[] = "/* @noflip */#article, /* @noflip
*/#mw-data-after-content { margin-left: 152px; margin-right: 4px; }";
+ $rules[] = "/* @noflip */#article,
#mw-data-after-content { margin-left: 152px; margin-right: 4px; }";
if( 3 == $qb ) {
$rules[] = "/* @noflip */#quickbar { position:
fixed; padding: 4px; }";
}
} elseif ( 4 == $qb ) {
$rules[] = "/* @noflip */#quickbar { position: fixed;
right: 0px; top: 0px; padding: 4px;}";
$rules[] = "/* @noflip */#quickbar { border-right: 1px
solid gray; }";
- $rules[] = "/* @noflip */#article, /* @noflip
*/#mw-data-after-content { margin-right: 152px; margin-left: 4px; }";
+ $rules[] = "/* @noflip */#article,
#mw-data-after-content { margin-right: 152px; margin-left: 4px; }";
}
$style = implode( "\n", $rules );
- $out->addInlineStyle( $style, /* flip css if RTL */true );
+ $out->addInlineStyle( $style, 'flip' );
}
}
Modified: branches/wmf/1.18wmf1/skins/common/shared.css
===================================================================
--- branches/wmf/1.18wmf1/skins/common/shared.css 2011-09-20 15:33:17 UTC
(rev 97634)
+++ branches/wmf/1.18wmf1/skins/common/shared.css 2011-09-20 15:54:15 UTC
(rev 97635)
@@ -732,6 +732,13 @@
margin: 0 2em 0 0;
}
+#toc #toctitle,
+.toc #toctitle,
+#toc .toctitle,
+.toc .toctitle {
+ direction: ltr;
+}
+
/* tooltip styles */
.mw-help-field-hint {
display: none;
_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs