/*!
- * OOUI v0.26.3
+ * OOUI v0.26.4
* https://www.mediawiki.org/wiki/OOUI
*
* Copyright 2011–2018 OOUI Team and other contributors.
* Released under the MIT license
* http://oojs.mit-license.org
*
- * Date: 2018-04-10T22:15:39Z
+ * Date: 2018-04-17T22:23:58Z
*/
( function ( OO ) {
* @param {jQuery.Event} e Window resize event
*/
OO.ui.WindowManager.prototype.afterWindowResize = function () {
+ var currentFocusedElement = document.activeElement;
if ( this.currentWindow ) {
this.updateWindowSize( this.currentWindow );
+
+ // Restore focus to the original element if it has changed.
+ // When a layout change is made on resize inputs lose focus
+ // on Android (Chrome and Firefox). See T162127.
+ if ( currentFocusedElement !== document.activeElement ) {
+ currentFocusedElement.focus();
+ }
}
};