diff options
author | Luke Shumaker <lukeshu@sbcglobal.net> | 2016-05-01 15:32:59 -0400 |
---|---|---|
committer | Luke Shumaker <lukeshu@sbcglobal.net> | 2016-05-01 15:32:59 -0400 |
commit | 6dc1997577fab2c366781fd7048144935afa0012 (patch) | |
tree | 8918d28c7ab4342f0738985e37af1dfc42d0e93a /vendor/oojs/oojs-ui/src/widgets/RadioOptionWidget.js | |
parent | 150f94f051128f367bc89f6b7e5f57eb2a69fc62 (diff) | |
parent | fa89acd685cb09cdbe1c64cbb721ec64975bbbc1 (diff) |
Merge commit 'fa89acd'
# Conflicts:
# .gitignore
# extensions/ArchInterWiki.sql
Diffstat (limited to 'vendor/oojs/oojs-ui/src/widgets/RadioOptionWidget.js')
-rw-r--r-- | vendor/oojs/oojs-ui/src/widgets/RadioOptionWidget.js | 66 |
1 files changed, 0 insertions, 66 deletions
diff --git a/vendor/oojs/oojs-ui/src/widgets/RadioOptionWidget.js b/vendor/oojs/oojs-ui/src/widgets/RadioOptionWidget.js deleted file mode 100644 index 97187c0a..00000000 --- a/vendor/oojs/oojs-ui/src/widgets/RadioOptionWidget.js +++ /dev/null @@ -1,66 +0,0 @@ -/** - * RadioOptionWidget is an option widget that looks like a radio button. - * The class is used with OO.ui.RadioSelectWidget to create a selection of radio options. - * Please see the [OOjs UI documentation on MediaWiki] [1] for more information. - * - * [1]: https://www.mediawiki.org/wiki/OOjs_UI/Widgets/Selects_and_Options#Button_selects_and_option - * - * @class - * @extends OO.ui.OptionWidget - * - * @constructor - * @param {Object} [config] Configuration options - */ -OO.ui.RadioOptionWidget = function OoUiRadioOptionWidget( config ) { - // Configuration initialization - config = config || {}; - - // Properties (must be done before parent constructor which calls #setDisabled) - this.radio = new OO.ui.RadioInputWidget( { value: config.data, tabIndex: -1 } ); - - // Parent constructor - OO.ui.RadioOptionWidget.super.call( this, config ); - - // Initialization - this.$element - .addClass( 'oo-ui-radioOptionWidget' ) - .prepend( this.radio.$element ); -}; - -/* Setup */ - -OO.inheritClass( OO.ui.RadioOptionWidget, OO.ui.OptionWidget ); - -/* Static Properties */ - -OO.ui.RadioOptionWidget.static.highlightable = false; - -OO.ui.RadioOptionWidget.static.scrollIntoViewOnSelect = true; - -OO.ui.RadioOptionWidget.static.pressable = false; - -OO.ui.RadioOptionWidget.static.tagName = 'label'; - -/* Methods */ - -/** - * @inheritdoc - */ -OO.ui.RadioOptionWidget.prototype.setSelected = function ( state ) { - OO.ui.RadioOptionWidget.super.prototype.setSelected.call( this, state ); - - this.radio.setSelected( state ); - - return this; -}; - -/** - * @inheritdoc - */ -OO.ui.RadioOptionWidget.prototype.setDisabled = function ( disabled ) { - OO.ui.RadioOptionWidget.super.prototype.setDisabled.call( this, disabled ); - - this.radio.setDisabled( this.isDisabled() ); - - return this; -}; |