r87353 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r87352‎ | r87353 | r87354 >
Date:20:27, 3 May 2011
Author:catrope
Status:resolved (Comments)
Tags:
Comment:
Modified paths:
  • /branches/wmf/1.17wmf1/extensions/GoogleNewsSitemap/GoogleNewsSitemap_body.php (modified) (history)
  • /branches/wmf/1.17wmf1/extensions/ParserFunctions/ParserFunctions_body.php (modified) (history)
  • /branches/wmf/1.17wmf1/extensions/Vector/modules/ext.vector.collapsibleTabs.js (modified) (history)
  • /branches/wmf/1.17wmf1/includes/Linker.php (modified) (history)
  • /branches/wmf/1.17wmf1/includes/parser/CoreParserFunctions.php (modified) (history)
  • /branches/wmf/1.17wmf1/includes/specials/SpecialIpblocklist.php (modified) (history)
  • /branches/wmf/1.17wmf1/resources/jquery/jquery.collapsibleTabs.js (modified) (history)
  • /branches/wmf/1.17wmf1/resources/mediawiki/mediawiki.js (modified) (history)
  • /branches/wmf/1.17wmf1/skins/common/commonPrint.css (modified) (history)
  • /branches/wmf/1.17wmf1/skins/common/diff.css (modified) (history)
  • /branches/wmf/1.17wmf1/skins/common/shared.css (modified) (history)
  • /branches/wmf/1.17wmf1/skins/monobook/main.css (modified) (history)
  • /branches/wmf/1.17wmf1/skins/vector/screen.css (modified) (history)

Diff [purge]

Index: branches/wmf/1.17wmf1/skins/monobook/main.css
@@ -59,7 +59,6 @@
6060
6161 table {
6262 font-size: 100%;
63 - color: black;
6463 }
6564 a {
6665 text-decoration: none;
Index: branches/wmf/1.17wmf1/skins/common/commonPrint.css
@@ -44,6 +44,9 @@
4545 div.floatleft p {
4646 font-style: italic;
4747 }
 48+div.center {
 49+ text-align: center;
 50+}
4851
4952 /* thumbnails */
5053 div.thumb {
Index: branches/wmf/1.17wmf1/skins/common/shared.css
@@ -556,6 +556,7 @@
557557 background: #f9f9f9;
558558 border: 1px #aaa solid;
559559 border-collapse: collapse;
 560+ color: black;
560561 }
561562 .wikitable th, .wikitable td {
562563 border: 1px #aaa solid;
Property changes on: branches/wmf/1.17wmf1/skins/common/shared.css
___________________________________________________________________
Modified: svn:mergeinfo
563564 Merged /trunk/phase3/skins/common/shared.css:r85546,86450,86625,86788,86841,86904,87030
564565 Merged /branches/REL1_17/phase3/skins/common/shared.css:r86409
Index: branches/wmf/1.17wmf1/skins/common/diff.css
@@ -54,8 +54,10 @@
5555 }
5656 table.diff td div {
5757 /* Force-wrap very long lines such as URLs or page-widening char strings.
58 - CSS 3 draft..., but Gecko doesn't support it yet:
59 - https://bugzilla.mozilla.org/show_bug.cgi?id=99457 */
 58+ CSS 3 only (In Gecko 1.9.1 / Firefox 3.5):
 59+ https://bugzilla.mozilla.org/show_bug.cgi?id=99457
 60+ https://developer.mozilla.org/web-tech/2008/08/20/word-wrap-break-word/
 61+ https://developer.mozilla.org/En/CSS/Word-wrap */
6062 word-wrap: break-word;
6163
6264 /* As fallback, scrollbars will be added for very wide cells
Index: branches/wmf/1.17wmf1/skins/vector/screen.css
@@ -73,7 +73,6 @@
7474 #p-personal {
7575 position: absolute;
7676 top: 0;
77 - padding-left: 10em;
7877 right: 0.75em;
7978 }
8079 #p-personal h5 {
@@ -82,7 +81,7 @@
8382 #p-personal ul {
8483 list-style: none;
8584 margin: 0;
86 - padding: 0;
 85+ padding-left: 10em; /* Keep from overlapping logo */
8786 }
8887 /* @noflip */
8988 #p-personal li {
@@ -825,7 +824,6 @@
826825 /* Tables */
827826 table {
828827 font-size: 100%;
829 - color: black;
830828 }
831829 /* Forms */
832830 fieldset {
Property changes on: branches/wmf/1.17wmf1/skins/vector/screen.css
___________________________________________________________________
Modified: svn:mergeinfo
833831 Merged /branches/REL1_17/phase3/skins/vector/screen.css:r86409
834832 Merged /trunk/phase3/skins/vector/screen.css:r85546,86450,86625,86788,86841,86904,87030
Index: branches/wmf/1.17wmf1/extensions/ParserFunctions/ParserFunctions_body.php
@@ -415,6 +415,11 @@
416416 # if local time was not requested, convert to UTC
417417 $tz = new DateTimeZone( 'UTC' );
418418 }
 419+
 420+ # Correct for DateTime interpreting 'XXXX' as XX:XX o'clock
 421+ if ( preg_match( '/^[0-9]{4}$/', $date ) ) {
 422+ $date = '00:00 '.$date;
 423+ }
419424
420425 # Parse date
421426 if ( $date !== '' ) {
Index: branches/wmf/1.17wmf1/extensions/Vector/modules/ext.vector.collapsibleTabs.js
@@ -28,7 +28,7 @@
2929 $( this ).hide();
3030 // add the placeholder
3131 $( '<span class="placeholder" style="display:none;"></span>' ).insertAfter( this );
32 - $( this ).remove().prependTo( target ).data( 'collapsibleTabsSettings', data );
 32+ $( this ).detach().prependTo( target ).data( 'collapsibleTabsSettings', data );
3333 $( this ).attr( 'style', 'display:list-item;' );
3434 //$.collapsibleTabs.getSettings( $( $.collapsibleTabs.getSettings( $( ele ) ).expandedContainer ) )
3535 // .shifting = false;
@@ -65,13 +65,13 @@
6666 var $target = $( data.expandedContainer ).find( 'span.placeholder:first' );
6767 var expandedWidth = data.expandedWidth;
6868 $moving.css( "position", "relative" ).css( ( rtl ? 'right' : 'left' ), 0 ).css( 'width', '1px' );
69 - $target.replaceWith( $moving.remove().css( 'width', '1px' ).data( 'collapsibleTabsSettings', data )
70 - .animate( { width: expandedWidth+"px" }, "normal", function() {
 69+ $target.replaceWith( $moving.detach().css( 'width', '1px' ).data( 'collapsibleTabsSettings', data )
 70+ .animate( { width: expandedWidth+"px" }, "normal", function( ) {
7171 $( this ).attr( 'style', 'display:block;' );
7272 //$.collapsibleTabs.getSettings( $( $.collapsibleTabs.getSettings( $( ele ) ).expandedContainer ) )
7373 // .shifting = false;
7474 // Do the above, except with guards for JS errors
75 - var data = $.collapsibleTabs.getSettings( $( ele ) );
 75+ var data = $.collapsibleTabs.getSettings( $( this ) );
7676 if ( !data ) {
7777 return;
7878 }
Property changes on: branches/wmf/1.17wmf1/extensions/Vector/modules/ext.vector.collapsibleTabs.js
___________________________________________________________________
Modified: svn:mergeinfo
7979 Merged /branches/REL1_17/phase3/extensions/Vector/modules/ext.vector.collapsibleTabs.js:r86409
8080 Merged /trunk/extensions/Vector/modules/ext.vector.collapsibleTabs.js:r86625,86805,87153
Index: branches/wmf/1.17wmf1/extensions/GoogleNewsSitemap/GoogleNewsSitemap_body.php
@@ -276,20 +276,20 @@
277277 $conditions['page_namespace'] = $params['namespace'];
278278 }
279279
280 - wfRunHooks('GoogleNewsSitemap::Query', array($params, &$joins, &$conditions, &$tables));
 280+ $joins = array();
 281+ wfRunHooks('GoogleNewsSitemap::Query', array($params, &$joins, &$conditions));
281282
282283 switch ( $params['redirects'] ) {
283284 case self::OPT_ONLY:
284285 $conditions['page_is_redirect'] = 1;
285 - break;
 286+ break;
286287 case self::OPT_EXCLUDE:
287288 $conditions['page_is_redirect'] = 0;
288 - break;
 289+ break;
289290 }
290291
291292 if ( $params['hourCount'] > 0
292 - && $params['orderMethod'] !== 'lastedit' )
293 - {
 293+ && $params['orderMethod'] !== 'lastedit' ) {
294294 // Limit to last X number of hours added to category,
295295 // if hourcont is positive and we're sorting by
296296 // category add date.
@@ -341,7 +341,6 @@
342342 $options['ORDER BY'] = 'c1.cl_timestamp ' . $sortOrder;
343343 }
344344
345 -
346345 // earlier validation logic ensures this is a reasonable number
347346 $options['LIMIT'] = $params['count'];
348347
@@ -354,7 +353,7 @@
355354 * variables that make up the request.
356355 **/
357356 public function getParams() {
358 - global $wgContLang, $wgRequest, $wgGNSMmaxCategories,
 357+ global $wgRequest, $wgGNSMmaxCategories,
359358 $wgGNSMmaxResultCount, $wgGNSMfallbackCategory;
360359
361360 $params = array();
@@ -368,8 +367,7 @@
369368 $params['hourCount'] = $wgRequest->getInt( 'hourcount', -1 );
370369
371370 if ( ( $params['count'] > $wgGNSMmaxResultCount )
372 - || ( $params['count'] < 1 ) )
373 - {
 371+ || ( $params['count'] < 1 ) ) {
374372 $params['count'] = $wgGNSMmaxResultCount;
375373 }
376374
Index: branches/wmf/1.17wmf1/includes/parser/CoreParserFunctions.php
@@ -639,7 +639,7 @@
640640 }
641641
642642 if ( $file ) {
643 - $url = $file->getUrl();
 643+ $url = $file->getFullUrl();
644644
645645 // If a size is requested...
646646 if ( is_integer( $size ) ) {
Index: branches/wmf/1.17wmf1/includes/Linker.php
@@ -199,7 +199,7 @@
200200
201201 $attribs = array_merge(
202202 $attribs,
203 - $this->linkAttribs( $target, $customAttribs, $options, $text )
 203+ $this->linkAttribs( $target, $customAttribs, $options )
204204 );
205205 if ( is_null( $text ) ) {
206206 $text = $this->linkText( $target );
@@ -249,7 +249,7 @@
250250 /**
251251 * Returns the array of attributes used when linking to the Title $target
252252 */
253 - private function linkAttribs( $target, $attribs, $options, $linkText ) {
 253+ private function linkAttribs( $target, $attribs, $options ) {
254254 wfProfileIn( __METHOD__ );
255255 global $wgUser;
256256 $defaults = array();
@@ -280,13 +280,12 @@
281281 }
282282
283283 # Get a default title attribute.
284 - $known = in_array( 'known', $options );
285284 if ( $target->getPrefixedText() == '' ) {
286285 # A link like [[#Foo]]. This used to mean an empty title
287286 # attribute, but that's silly. Just don't output a title.
288 - } elseif ( $known && strtolower($linkText) !== strtolower($target->getPrefixedText() ) ) {
 287+ } elseif ( in_array( 'known', $options ) ) {
289288 $defaults['title'] = $target->getPrefixedText();
290 - } elseif ( !$known ) {
 289+ } else {
291290 $defaults['title'] = wfMsg( 'red-link-title', $target->getPrefixedText() );
292291 }
293292
Index: branches/wmf/1.17wmf1/includes/specials/SpecialIpblocklist.php
@@ -77,7 +77,7 @@
7878 $block = Block::newFromID( $this->id );
7979 $user = User::newFromName( $block->mAddress );
8080 } else {
81 - $user = User::newFromName( $ip );
 81+ $user = User::newFromName( $this->ip );
8282 }
8383 $status = IPBlockForm::checkUnblockSelf( $user );
8484 if ( $status !== true ) {
Index: branches/wmf/1.17wmf1/resources/jquery/jquery.collapsibleTabs.js
@@ -49,12 +49,14 @@
5050 },
5151 addData: function( $collapsible ) {
5252 var $settings = $collapsible.parent().data( 'collapsibleTabsSettings' );
53 - $collapsible.data( 'collapsibleTabsSettings', {
54 - 'expandedContainer': $settings.expandedContainer,
55 - 'collapsedContainer': $settings.collapsedContainer,
56 - 'expandedWidth': $collapsible.width(),
57 - 'prevElement': $collapsible.prev()
58 - } );
 53+ if ( $settings != null ) {
 54+ $collapsible.data( 'collapsibleTabsSettings', {
 55+ 'expandedContainer': $settings.expandedContainer,
 56+ 'collapsedContainer': $settings.collapsedContainer,
 57+ 'expandedWidth': $collapsible.width(),
 58+ 'prevElement': $collapsible.prev()
 59+ } );
 60+ }
5961 },
6062 getSettings: function( $collapsible ) {
6163 var $settings = $collapsible.data( 'collapsibleTabsSettings' );
@@ -95,7 +97,7 @@
9698 var dataExp = $.collapsibleTabs.getSettings( data.expandedContainer );
9799 dataExp.shifting = true;
98100 $moving
99 - .remove()
 101+ .detach()
100102 .prependTo( data.collapsedContainer )
101103 .data( 'collapsibleTabsSettings', data );
102104 dataExp.shifting = false;
@@ -107,9 +109,9 @@
108110 var dataExp = $.collapsibleTabs.getSettings( data.expandedContainer );
109111 dataExp.shifting = true;
110112 // remove this element from where it's at and put it in the dropdown menu
111 - $moving.remove().insertAfter( data.prevElement ).data( 'collapsibleTabsSettings', data );
 113+ $moving.detach().insertAfter( data.prevElement ).data( 'collapsibleTabsSettings', data );
112114 dataExp.shifting = false;
113115 $.collapsibleTabs.handleResize();
114116 }
115117 };
116 -} )( jQuery );
\ No newline at end of file
 118+} )( jQuery );
Index: branches/wmf/1.17wmf1/resources/mediawiki/mediawiki.js
@@ -1004,9 +1004,7 @@
10051005 // Allow calling with an external script or single dependency as a string
10061006 if ( typeof modules === 'string' ) {
10071007 // Support adding arbitrary external scripts
1008 - if ( modules.substr( 0, 7 ) == 'http://'
1009 - || modules.substr( 0, 8 ) == 'https://' )
1010 - {
 1008+ if ( modules.substr( 0, 7 ) == 'http://' || modules.substr( 0, 8 ) == 'https://' ) {
10111009 if ( type === 'text/css' ) {
10121010 $( 'head' )
10131011 .append( $( '<link rel="stylesheet" type="text/css" />' )
Property changes on: branches/wmf/1.17wmf1/resources/mediawiki/mediawiki.js
___________________________________________________________________
Modified: svn:mergeinfo
10141012 Merged /trunk/phase3/resources/mediawiki/mediawiki.js:r85546,86450,86625,86788,86841,86904,87030
10151013 Merged /branches/REL1_17/phase3/resources/mediawiki/mediawiki.js:r86409

Follow-up revisions

RevisionCommit summaryAuthorDate
r874481.17wmf1: Partially revert r87353, which per CR messed up GNSMcatrope20:28, 4 May 2011

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r85546Remove color:black from table {} in skins (bug 28422) + small fixes...krinkle16:31, 6 April 2011
r86409(bug 28352) "blocked admins actually can't unblock themselves because it chec...happy-melon16:04, 19 April 2011
r86450fixing bug 28438 - header links displaying incorrectly in rlt IE9. Also remov...kaldari01:42, 20 April 2011
r86625(bug 27833) CollapsibleTabs doesn't collapse tabs due to JS errors...catrope14:39, 21 April 2011
r86788Change getUrl to getFullUrl for {{filepath:Filename.jpg}} of non-thumbd local...krinkle19:38, 23 April 2011
r86805fix for bug 28655 - #time interpreting years incorrectlykaldari01:10, 24 April 2011
r86841Followup r86625: per CR, use loose comparison against null instead of typeof ...catrope10:17, 25 April 2011
r86904fix for bug 28573 - in printable version centered images are not centeredkaldari21:37, 25 April 2011
r87030revert r76127, r76129, and r83535 b/c I'm backing out the fix for bug #542. ...mah19:13, 27 April 2011
r87153Fix undefined variable used in hook call...reedy00:17, 30 April 2011

Comments

#Comment by Bawolff (talk | contribs)   20:23, 4 May 2011

This appears to revert GoogleNewsSitemap to an older version despite none of the revisions listed touch the extension.

Status & tagging log