mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/DiscussionTools
synced 2024-11-30 11:07:24 +00:00
17 lines
480 B
JavaScript
17 lines
480 B
JavaScript
|
function ModeTabSelectWidget() {
|
||
|
// Parent constructor
|
||
|
ModeTabSelectWidget.super.apply( this, arguments );
|
||
|
}
|
||
|
|
||
|
OO.inheritClass( ModeTabSelectWidget, OO.ui.TabSelectWidget );
|
||
|
|
||
|
ModeTabSelectWidget.prototype.onDocumentKeyDown = function ( e ) {
|
||
|
// Handle Space like Enter
|
||
|
if ( e.keyCode === OO.ui.Keys.SPACE ) {
|
||
|
e = $.Event( e, { keyCode: OO.ui.Keys.ENTER } );
|
||
|
}
|
||
|
ModeTabSelectWidget.super.prototype.onDocumentKeyDown.call( this, e );
|
||
|
};
|
||
|
|
||
|
module.exports = ModeTabSelectWidget;
|