New changes:
d40dd30 build: Update grunt-contrib-uglify to v0.6.0
0d89c99 test: Load a theme for the test HTML file so the tests don't fail
f245aa4 Element: Remove test for deprecated onDOMEvent()
cd15f18 Follow-up I730e3d7d: Tab not spaces
a923881 build: Use Karma instead of grunt-contrib-qunit
381864c build: Use Chrome and Firefox for tests instead of PhantomJS
044faa5 Follow-up If2da01a2: Fix grunt watch
d6e7af8 Adding OO.ui.TitledElement as mixin to label widget
6385af7 MediaWiki theme: Add filled white background to toolbars
837b2f7 Revert "Try to stop user from tabbing outside of open dialog box"
Change-Id: I63d51311f73d1295a2a35ebadf7d9ac835dec5c7
/*!
- * OOjs UI v0.1.0-pre (26dadbc60f)
+ * OOjs UI v0.1.0-pre (837b2f733e)
* 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: 2014-10-06T16:03:50Z
+ * Date: 2014-10-11T01:05:40Z
*/
/* @noflip */
.oo-ui-rtl {
/*!
- * OOjs UI v0.1.0-pre (26dadbc60f)
+ * OOjs UI v0.1.0-pre (837b2f733e)
* 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: 2014-10-06T16:03:39Z
+ * Date: 2014-10-11T01:05:29Z
*/
/* Instantiation */
/*!
- * OOjs UI v0.1.0-pre (26dadbc60f)
+ * OOjs UI v0.1.0-pre (837b2f733e)
* 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: 2014-10-06T16:03:50Z
+ * Date: 2014-10-11T01:05:40Z
*/
/* @noflip */
.oo-ui-rtl {
/*!
- * OOjs UI v0.1.0-pre (26dadbc60f)
+ * OOjs UI v0.1.0-pre (837b2f733e)
* 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: 2014-10-06T16:03:50Z
+ * Date: 2014-10-11T01:05:40Z
*/
/* @noflip */
.oo-ui-rtl {
}
.oo-ui-toolbar-bar {
border-bottom: solid 1px #cccccc;
+ background: #ffffff;
}
.oo-ui-toolbar-bar .oo-ui-toolbar-bar {
border: none;
/*!
- * OOjs UI v0.1.0-pre (26dadbc60f)
+ * OOjs UI v0.1.0-pre (837b2f733e)
* 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: 2014-10-06T16:03:39Z
+ * Date: 2014-10-11T01:05:29Z
*/
/**
* @class
/*!
- * OOjs UI v0.1.0-pre (26dadbc60f)
+ * OOjs UI v0.1.0-pre (837b2f733e)
* 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: 2014-10-06T16:03:50Z
+ * Date: 2014-10-11T01:05:40Z
*/
/* @noflip */
.oo-ui-rtl {
}
.oo-ui-toolbar-bar {
border-bottom: solid 1px #cccccc;
+ background: #ffffff;
}
.oo-ui-toolbar-bar .oo-ui-toolbar-bar {
border: none;
/*!
- * OOjs UI v0.1.0-pre (26dadbc60f)
+ * OOjs UI v0.1.0-pre (837b2f733e)
* 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: 2014-10-06T16:03:50Z
+ * Date: 2014-10-11T01:05:40Z
*/
/* @noflip */
.oo-ui-rtl {
/*!
- * OOjs UI v0.1.0-pre (26dadbc60f)
+ * OOjs UI v0.1.0-pre (837b2f733e)
* 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: 2014-10-06T16:03:39Z
+ * Date: 2014-10-11T01:05:29Z
*/
/* Instantiation */
/*!
- * OOjs UI v0.1.0-pre (26dadbc60f)
+ * OOjs UI v0.1.0-pre (837b2f733e)
* 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: 2014-10-06T16:03:50Z
+ * Date: 2014-10-11T01:05:40Z
*/
/* @noflip */
.oo-ui-rtl {
/*!
- * OOjs UI v0.1.0-pre (26dadbc60f)
+ * OOjs UI v0.1.0-pre (837b2f733e)
* 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: 2014-10-06T16:03:39Z
+ * Date: 2014-10-11T01:05:29Z
*/
( function ( OO ) {
this.$head = this.$( '<div>' );
this.$body = this.$( '<div>' );
this.$foot = this.$( '<div>' );
- this.$focusTrap = this.$( '<div>' ).prop( 'tabIndex', 0 );
// Events
this.$element.on( 'mousedown', OO.ui.bind( this.onMouseDown, this ) );
this.$head.addClass( 'oo-ui-window-head' );
this.$body.addClass( 'oo-ui-window-body' );
this.$foot.addClass( 'oo-ui-window-foot' );
- this.$focusTrap.addClass( 'oo-ui-window-focustrap' );
- this.$content.append( this.$head, this.$body, this.$foot, this.$focusTrap );
+ this.$content.append( this.$head, this.$body, this.$foot );
return this;
};
-/**
- * Called when someone tries to focus the hidden element at the end of the dialog.
- * Sends focus back to the start of the dialog.
- */
-OO.ui.Window.prototype.onFocusTrapFocused = function () {
- this.$content.find( ':focusable:first' ).focus();
-};
-
/**
* Open window.
*
this.$element.show();
this.visible = true;
- this.focusTrapHandler = OO.ui.bind( this.onFocusTrapFocused, this );
- this.$focusTrap.on( 'focus', this.focusTrapHandler );
this.getSetupProcess( data ).execute().done( function () {
// Force redraw by asking the browser to measure the elements' widths
win.$element.addClass( 'oo-ui-window-setup' ).width();
var win = this,
deferred = $.Deferred();
- this.getTeardownProcess( data ).execute().done( OO.ui.bind( function () {
+ this.getTeardownProcess( data ).execute().done( function () {
// Force redraw by asking the browser to measure the elements' widths
win.$element.removeClass( 'oo-ui-window-setup' ).width();
win.$content.removeClass( 'oo-ui-window-content-setup' ).width();
win.$element.hide();
- this.$focusTrap.off( 'focus', this.focusTrapHandler );
win.visible = false;
deferred.resolve();
- }, this ) );
+ } );
return deferred.promise();
};
// Mixin constructors
OO.ui.LabelElement.call( this, $.extend( {}, config, { $label: this.$element } ) );
+ OO.ui.TitledElement.call( this, config );
// Properties
this.input = config.input;
OO.inheritClass( OO.ui.LabelWidget, OO.ui.Widget );
OO.mixinClass( OO.ui.LabelWidget, OO.ui.LabelElement );
+OO.mixinClass( OO.ui.LabelWidget, OO.ui.TitledElement );
/* Static Properties */