https://www.mediawiki.org/wiki/Special:Code/MediaWiki/112637
Revision: 112637
Author: reedy
Date: 2012-02-28 21:02:17 +0000 (Tue, 28 Feb 2012)
Log Message:
-----------
MFT r111380, r111809, r111983, r112034, r112037, r112152
Modified Paths:
--------------
branches/REL1_19/phase3/RELEASE-NOTES-1.19
branches/REL1_19/phase3/includes/SkinTemplate.php
branches/REL1_19/phase3/includes/debug/Debug.php
branches/REL1_19/phase3/resources/Resources.php
branches/REL1_19/phase3/resources/mediawiki/mediawiki.debug.js
branches/REL1_19/phase3/resources/mediawiki.action/mediawiki.action.edit.js
branches/REL1_19/phase3/skins/common/shared.css
Added Paths:
-----------
branches/REL1_19/phase3/resources/mediawiki/mediawiki.debug.init.js
Property Changed:
----------------
branches/REL1_19/phase3/
branches/REL1_19/phase3/includes/
Property changes on: branches/REL1_19/phase3
___________________________________________________________________
Modified: svn:mergeinfo
- /branches/JSTesting:100352-107913
/branches/REL1_15/phase3:51646
/branches/REL1_17/phase3:81445,81448
/branches/new-installer/phase3:43664-66004
/branches/sqlite:58211-58321
/branches/wmf/1.18wmf1:97508,111667
/trunk/phase3:111002,111029,111034,111062,111067,111076,111085,111128,111144,111251,111478,111571,111574,111580,111597,111658,111673,111695,111697,111832,112021
+ /branches/JSTesting:100352-107913
/branches/REL1_15/phase3:51646
/branches/REL1_17/phase3:81445,81448
/branches/new-installer/phase3:43664-66004
/branches/sqlite:58211-58321
/branches/wmf/1.18wmf1:97508,111667
/trunk/phase3:111002,111029,111034,111062,111067,111076,111085,111128,111144,111251,111380,111478,111571,111574,111580,111597,111658,111673,111695,111697,111809,111832,111983,112021,112034,112037,112152
Modified: branches/REL1_19/phase3/RELEASE-NOTES-1.19
===================================================================
--- branches/REL1_19/phase3/RELEASE-NOTES-1.19 2012-02-28 20:57:56 UTC (rev
112636)
+++ branches/REL1_19/phase3/RELEASE-NOTES-1.19 2012-02-28 21:02:17 UTC (rev
112637)
@@ -246,8 +246,8 @@
getText() on a non-object
* (bug 31676) Group dynamically inserted CSS into a single <style> tag, to work
around a bug where not all styles were applied in Internet Explorer
-* (bug 28936, bug 5280) Broken or invalid titles can't be removed from
watchlist.
-* (Bug 33087) Exchange server rejected mail sent by MediaWiki
+* (bug 28936, bug 5280) Broken or invalid titles can't be removed from
watchlist.* (Bug 33087) Exchange server rejected mail sent by MediaWiki
+* (bug 34600) Older skins using useHeadElement=false were broken in 1.18
=== API changes in 1.19 ===
* Made action=edit less likely to return "unknownerror", by returning the
actual error
Property changes on: branches/REL1_19/phase3/includes
___________________________________________________________________
Modified: svn:mergeinfo
- /branches/JSTesting/includes:100352-107913
/branches/REL1_15/phase3/includes:51646
/branches/new-installer/phase3/includes:43664-66004
/branches/sqlite/includes:58211-58321
/branches/wmf/1.18wmf1/includes:97508,111667
/branches/wmf-deployment/includes:53381
/trunk/phase3/includes:111029,111034,111067,111085,111128,111144,111251,111571,111574,111597,111658,111673,111695,111697,111832,112021
+ /branches/JSTesting/includes:100352-107913
/branches/REL1_15/phase3/includes:51646
/branches/new-installer/phase3/includes:43664-66004
/branches/sqlite/includes:58211-58321
/branches/wmf/1.18wmf1/includes:97508,111667
/branches/wmf-deployment/includes:53381
/trunk/phase3/includes:111029,111034,111067,111085,111128,111144,111251,111380,111571,111574,111597,111658,111673,111695,111697,111809,111832,111983,112021,112034,112037,112152
Modified: branches/REL1_19/phase3/includes/SkinTemplate.php
===================================================================
--- branches/REL1_19/phase3/includes/SkinTemplate.php 2012-02-28 20:57:56 UTC
(rev 112636)
+++ branches/REL1_19/phase3/includes/SkinTemplate.php 2012-02-28 21:02:17 UTC
(rev 112637)
@@ -455,7 +455,7 @@
if ( $this->useHeadElement ) {
$tpl->set( 'headelement', $out->headElement( $this ) );
} else {
- $tpl->set( 'headscripts', $out->getScript() );
+ $tpl->set( 'headscripts', $out->getHeadScripts() .
$out->getHeadItems() );
}
$tpl->set( 'debughtml', $this->generateDebugHTML() );
Modified: branches/REL1_19/phase3/includes/debug/Debug.php
===================================================================
--- branches/REL1_19/phase3/includes/debug/Debug.php 2012-02-28 20:57:56 UTC
(rev 112636)
+++ branches/REL1_19/phase3/includes/debug/Debug.php 2012-02-28 21:02:17 UTC
(rev 112637)
@@ -62,7 +62,7 @@
*/
public static function addModules( OutputPage $out ) {
if ( self::$enabled ) {
- $out->addModules( 'mediawiki.debug' );
+ $out->addModules( 'mediawiki.debug.init' );
}
}
@@ -271,12 +271,15 @@
'memoryPeak' => $context->getLanguage()->formatSize(
memory_get_peak_usage() ),
'includes' => self::getFilesIncluded( $context ),
);
- // TODO: Clean this up
- $html = Html::openElement( 'script' );
- $html .= 'var debugInfo = ' . Xml::encodeJsVar( $debugInfo ) .
';';
- $html .= " $(function() { mw.loader.using( 'mediawiki.debug',
function() { mw.Debug.init( debugInfo ) } ); }); ";
- $html .= Html::closeElement( 'script' );
+ // Cannot use OutputPage::addJsConfigVars because those are
already outputted
+ // by the time this method is called.
+ $html = Html::inlineScript(
+ ResourceLoader::makeLoaderConditionalScript(
+ ResourceLoader::makeConfigSetScript( array(
'debugInfo' => $debugInfo ) )
+ )
+ );
+
return $html;
}
}
Modified: branches/REL1_19/phase3/resources/Resources.php
===================================================================
--- branches/REL1_19/phase3/resources/Resources.php 2012-02-28 20:57:56 UTC
(rev 112636)
+++ branches/REL1_19/phase3/resources/Resources.php 2012-02-28 21:02:17 UTC
(rev 112637)
@@ -537,13 +537,21 @@
),
'mediawiki.api.watch' => array(
'scripts' => 'resources/mediawiki.api/mediawiki.api.watch.js',
- 'dependencies' => 'mediawiki.api',
+ 'dependencies' => array('mediawiki.api', 'mediawiki.user'),
),
'mediawiki.debug' => array(
'scripts' => 'resources/mediawiki/mediawiki.debug.js',
'styles' => 'resources/mediawiki/mediawiki.debug.css',
'dependencies' => 'jquery.footHovzer',
+ 'position' => 'bottom',
),
+ 'mediawiki.debug.init' => array(
+ 'scripts' => 'resources/mediawiki/mediawiki.debug.init.js',
+ 'dependencies' => 'mediawiki.debug',
+ // Uses a custom mw.config variable that is set in debughtml,
+ // must be loaded on the bottom
+ 'position' => 'bottom',
+ ),
'mediawiki.feedback' => array(
'scripts' => 'resources/mediawiki/mediawiki.feedback.js',
'dependencies' => array(
Copied: branches/REL1_19/phase3/resources/mediawiki/mediawiki.debug.init.js
(from rev 111380, trunk/phase3/resources/mediawiki/mediawiki.debug.init.js)
===================================================================
--- branches/REL1_19/phase3/resources/mediawiki/mediawiki.debug.init.js
(rev 0)
+++ branches/REL1_19/phase3/resources/mediawiki/mediawiki.debug.init.js
2012-02-28 21:02:17 UTC (rev 112637)
@@ -0,0 +1,3 @@
+jQuery( function () {
+ mediaWiki.Debug.init();
+} );
Modified: branches/REL1_19/phase3/resources/mediawiki/mediawiki.debug.js
===================================================================
--- branches/REL1_19/phase3/resources/mediawiki/mediawiki.debug.js
2012-02-28 20:57:56 UTC (rev 112636)
+++ branches/REL1_19/phase3/resources/mediawiki/mediawiki.debug.js
2012-02-28 21:02:17 UTC (rev 112637)
@@ -1,5 +1,5 @@
/**
- * JavaScript for the new debug toolbar, enabled with $wgDebugToolbar
+ * JavaScript for the new debug toolbar, enabled through $wgDebugToolbar.
*
* @author John Du Hart
* @since 1.19
@@ -26,13 +26,15 @@
data: {},
/**
- * Initializes the debugging pane
+ * Initializes the debugging pane.
+ * Shouldn't be called before the document is ready
+ * (since it binds to elements on the page).
*
- * @param {Object} data
+ * @param {Object} data, defaults to 'debugInfo' from mw.config
*/
init: function ( data ) {
- this.data = data;
+ this.data = data || mw.config.get( 'debugInfo' );
this.buildHtml();
// Insert the container into the DOM
Modified:
branches/REL1_19/phase3/resources/mediawiki.action/mediawiki.action.edit.js
===================================================================
--- branches/REL1_19/phase3/resources/mediawiki.action/mediawiki.action.edit.js
2012-02-28 20:57:56 UTC (rev 112636)
+++ branches/REL1_19/phase3/resources/mediawiki.action/mediawiki.action.edit.js
2012-02-28 21:02:17 UTC (rev 112637)
@@ -3,7 +3,7 @@
var currentFocused = $( '#wpTextbox1' );
mw.toolbar = {
- $toolbar : $( '#toolbar' ),
+ $toolbar : [],
buttons : [],
// If you want to add buttons, use
// mw.toolbar.addButton( imageFile, speedTip, tagOpen,
tagClose, sampleText, imageId, selectText );
@@ -37,7 +37,12 @@
);
}
},
- init : function() {
+
+ // For backwards compatibility
+ init : function() {},
+
+ onReady : function() {
+ mw.toolbar.$toolbar = $( '#toolbar' );
// Legacy
// Merge buttons from mwCustomEditButtons
var buttons = [].concat( this.buttons,
window.mwCustomEditButtons );
@@ -59,10 +64,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
Modified: branches/REL1_19/phase3/skins/common/shared.css
===================================================================
--- branches/REL1_19/phase3/skins/common/shared.css 2012-02-28 20:57:56 UTC
(rev 112636)
+++ branches/REL1_19/phase3/skins/common/shared.css 2012-02-28 21:02:17 UTC
(rev 112637)
@@ -1023,7 +1023,8 @@
}
/* Accessibility */
-.mw-jump {
+.mw-jump,
+#jump-to-nav {
overflow: hidden;
height: 0;
zoom: 1; /* http://webaim.org/techniques/skipnav/#iequirk */
_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs