From: James D. Forrester Date: Tue, 15 Apr 2014 18:07:44 +0000 (-0700) Subject: Update OOjs UI to v0.1.0-pre (8197f2cd2e) X-Git-Tag: 1.31.0-rc.0~16207^2 X-Git-Url: http://git.cyclocoop.org/%40spipnet%40?a=commitdiff_plain;h=01a2682a86502d3ea2f6b3bdaea9991987bb7273;p=lhc%2Fweb%2Fwiklou.git Update OOjs UI to v0.1.0-pre (8197f2cd2e) New changes: 036b066 Make demos point to symlinks to /dist and /lib for doc publishing needs eba79af Followup d7cbc785a: focus iframe content div before open event 8197f2c Fix WindowSet#getCurrentWindow documentation Change-Id: I98c539eb4bc35c04142e4dd196db4ad567ed741c --- diff --git a/resources/lib/oojs-ui/oojs-ui.js b/resources/lib/oojs-ui/oojs-ui.js index 958bc1c4d4..3878a65b4a 100644 --- a/resources/lib/oojs-ui/oojs-ui.js +++ b/resources/lib/oojs-ui/oojs-ui.js @@ -1,12 +1,12 @@ /*! - * OOjs UI v0.1.0-pre (eca1fc20e7) + * OOjs UI v0.1.0-pre (8197f2cd2e) * https://www.mediawiki.org/wiki/OOjs_UI * * Copyright 2011–2014 OOjs Team and other contributors. * Released under the MIT license * http://oojs.mit-license.org * - * Date: Fri Apr 11 2014 16:47:56 GMT-0700 (PDT) + * Date: Tue Apr 15 2014 11:07:39 GMT-0700 (PDT) */ ( function ( OO ) { @@ -1293,12 +1293,13 @@ OO.ui.Window.prototype.open = function ( data ) { this.visible = true; this.emit( 'opening', data ); this.setup( data ); - this.emit( 'open', data ); - this.opening = false; // Focus the content div (which has a tabIndex) to inactivate // (but not clear) selections in the parent frame. - // Must happen after the window has opened. + // Must happen after setup runs (otherwise focusing it doesn't work) + // but before 'open' is emitted (so subclasses can give focus to something else) this.frame.$content.focus(); + this.emit( 'open', data ); + this.opening = false; }, this ) ); } @@ -1453,7 +1454,7 @@ OO.ui.WindowSet.prototype.onWindowClose = function ( win, config ) { /** * Get the current window. * - * @return {OO.ui.Window} Current window + * @return {OO.ui.Window|null} Current window or null if none open */ OO.ui.WindowSet.prototype.getCurrentWindow = function () { return this.currentWindow; diff --git a/resources/lib/oojs-ui/oojs-ui.svg.css b/resources/lib/oojs-ui/oojs-ui.svg.css index 7a7cffaf9c..0353288ecf 100644 --- a/resources/lib/oojs-ui/oojs-ui.svg.css +++ b/resources/lib/oojs-ui/oojs-ui.svg.css @@ -1,12 +1,12 @@ /*! - * OOjs UI v0.1.0-pre (eca1fc20e7) + * OOjs UI v0.1.0-pre (8197f2cd2e) * https://www.mediawiki.org/wiki/OOjs_UI * * Copyright 2011–2014 OOjs Team and other contributors. * Released under the MIT license * http://oojs.mit-license.org * - * Date: Fri Apr 11 2014 16:47:56 GMT-0700 (PDT) + * Date: Tue Apr 15 2014 11:07:39 GMT-0700 (PDT) */ /* Textures */