https://www.mediawiki.org/wiki/Special:Code/MediaWiki/112570

Revision: 112570
Author:   catrope
Date:     2012-02-28 02:55:48 +0000 (Tue, 28 Feb 2012)
Log Message:
-----------
1.19wmf1: MFT r111983, r112384, r112451, r112561, r112562, r112567

Modified Paths:
--------------
    branches/wmf/1.19wmf1/extensions/CheckUser/SpecialCheckUserLog.php
    branches/wmf/1.19wmf1/includes/logging/LogFormatter.php
    
branches/wmf/1.19wmf1/resources/jquery.ui/themes/vector/jquery.ui.datepicker.css
    branches/wmf/1.19wmf1/resources/mediawiki/mediawiki.js
    branches/wmf/1.19wmf1/resources/mediawiki.action/mediawiki.action.edit.js

Modified: branches/wmf/1.19wmf1/extensions/CheckUser/SpecialCheckUserLog.php
===================================================================
--- branches/wmf/1.19wmf1/extensions/CheckUser/SpecialCheckUserLog.php  
2012-02-28 02:55:36 UTC (rev 112569)
+++ branches/wmf/1.19wmf1/extensions/CheckUser/SpecialCheckUserLog.php  
2012-02-28 02:55:48 UTC (rev 112570)
@@ -60,6 +60,10 @@
                                }
                        }
                }
+
+               $out->addHTML( $this->getSkin()->makeKnownLinkObj( 
+                       Title::makeTitle( NS_SPECIAL, 'CheckUser' ), 
+                               wfMsgHtml( 'checkuser-log-return' ) ) );
                
                $searchTypes = array( 'initiator', 'target' );
                $select = "<select name=\"cuSearchType\" 
style='margin-top:.2em;'>\n";

Modified: branches/wmf/1.19wmf1/includes/logging/LogFormatter.php
===================================================================
--- branches/wmf/1.19wmf1/includes/logging/LogFormatter.php     2012-02-28 
02:55:36 UTC (rev 112569)
+++ branches/wmf/1.19wmf1/includes/logging/LogFormatter.php     2012-02-28 
02:55:48 UTC (rev 112570)
@@ -226,6 +226,20 @@
                                }
                                break;
 
+                       case 'protect':
+                               switch( $entry->getSubtype() ) {
+                               case 'protect':
+                                       $text = wfMsgExt( 'protectedarticle', 
$msgOpts, $target . ' ' . $parameters[0] );
+                                               break;
+                               case 'unprotect':
+                                       $text = wfMsgExt( 'unprotectedarticle', 
$msgOpts, $target );
+                                               break;
+                               case 'modify':
+                                       $text = wfMsgExt( 
'modifiedarticleprotection', $msgOpts, $target . ' ' . $parameters[0] );
+                                               break;
+                               }
+                               break;
+
                        case 'newusers':
                                switch( $entry->getSubtype() ) {
                                        case 'newusers':

Modified: 
branches/wmf/1.19wmf1/resources/jquery.ui/themes/vector/jquery.ui.datepicker.css
===================================================================
--- 
branches/wmf/1.19wmf1/resources/jquery.ui/themes/vector/jquery.ui.datepicker.css
    2012-02-28 02:55:36 UTC (rev 112569)
+++ 
branches/wmf/1.19wmf1/resources/jquery.ui/themes/vector/jquery.ui.datepicker.css
    2012-02-28 02:55:48 UTC (rev 112570)
@@ -1,6 +1,6 @@
 /* Datepicker
 ----------------------------------*/
-.ui-datepicker { width: 17em; padding: .2em .2em 0; }
+.ui-datepicker { width: 17em; padding: .2em .2em 0; display: none; }
 .ui-datepicker .ui-datepicker-header { position:relative; padding:.2em 0; }
 .ui-datepicker .ui-datepicker-prev, .ui-datepicker .ui-datepicker-next { 
position:absolute; top: 2px; width: 1.8em; height: 1.8em; }
 .ui-datepicker .ui-datepicker-prev-hover, .ui-datepicker 
.ui-datepicker-next-hover { top: 1px; }

Modified: branches/wmf/1.19wmf1/resources/mediawiki/mediawiki.js
===================================================================
--- branches/wmf/1.19wmf1/resources/mediawiki/mediawiki.js      2012-02-28 
02:55:36 UTC (rev 112569)
+++ branches/wmf/1.19wmf1/resources/mediawiki/mediawiki.js      2012-02-28 
02:55:48 UTC (rev 112570)
@@ -615,6 +615,7 @@
                                                        j -= 1;
                                                }
                                        }
+                                       throw e;
                                }
                        }
        
@@ -770,7 +771,6 @@
                                                console.log( 
'mw.loader::execute> Exception thrown by ' + module + ': ' + e.message );
                                        }
                                        registry[module].state = 'error';
-                                       throw e;
                                }
                        }
        

Modified: 
branches/wmf/1.19wmf1/resources/mediawiki.action/mediawiki.action.edit.js
===================================================================
--- branches/wmf/1.19wmf1/resources/mediawiki.action/mediawiki.action.edit.js   
2012-02-28 02:55:36 UTC (rev 112569)
+++ branches/wmf/1.19wmf1/resources/mediawiki.action/mediawiki.action.edit.js   
2012-02-28 02:55:48 UTC (rev 112570)
@@ -3,12 +3,17 @@
        var currentFocused = $( '#wpTextbox1' );
 
        mw.toolbar = {
-               $toolbar : $( '#toolbar' ),
+               $toolbar : false,
                buttons : [],
+               isReady : false,
                // If you want to add buttons, use
                // mw.toolbar.addButton( imageFile, speedTip, tagOpen, 
tagClose, sampleText, imageId, selectText );
                addButton : function() {
-                       this.buttons.push( [].slice.call( arguments ) );
+                       if ( this.isReady ) {
+                               this.insertButton.apply( this, arguments );
+                       } else {
+                               this.buttons.push( [].slice.call( arguments ) );
+                       }       
                },
                insertButton : function( imageFile, speedTip, tagOpen, 
tagClose, sampleText, imageId, selectText ) {
                        var image = $('<img>', {
@@ -37,18 +42,25 @@
                                );
                        }
                },
-               init : function() {
+
+               // For backwards compatibility
+               init : function() {},
+
+               onReady : function() {
+                       this.$toolbar = $( '#toolbar' );
+                       this.isReady = true;
                        // Legacy
                        // Merge buttons from mwCustomEditButtons
                        var buttons = [].concat( this.buttons, 
window.mwCustomEditButtons );
                        for ( var i = 0; i < buttons.length; i++ ) {
                                if ( $.isArray( buttons[i] ) ) {
                                        // Passes our button array as arguments
-                                       mw.toolbar.insertButton.apply( this, 
buttons[i] );
+                                       this.insertButton.apply( this, 
buttons[i] );
                                } else {
                                        // Legacy mwCustomEditButtons is an 
object
                                        var c = buttons[i];
-                                       mw.toolbar.insertButton( c.imageFile, 
c.speedTip, c.tagOpen, c.tagClose, c.sampleText, c.imageId, c.selectText );
+                                       this.insertButton( c.imageFile, 
c.speedTip, c.tagOpen, 
+                                               c.tagClose, c.sampleText, 
c.imageId, c.selectText );
                                }
                        }
                        return true;
@@ -59,10 +71,12 @@
        window.addButton =  mw.toolbar.addButton;
        window.insertTags = mw.toolbar.insertTags;
 
-       //make sure edit summary does not exceed byte limit
-       $( '#wpSummary' ).byteLimit( 250 );
+       $( document ).ready( function() {
+               mw.toolbar.onReady();
 
-       $( document ).ready( function() {
+               // Make sure edit summary does not exceed byte limit
+               $( '#wpSummary' ).byteLimit( 250 );
+
                /**
                 * Restore the edit box scroll state following a preview 
operation,
                 * and set up a form submission handler to remember this state


_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs

Reply via email to