2013-08-27 23:28:29 +00:00
|
|
|
/*!
|
|
|
|
* VisualEditor MediaWiki UserInterface dialog tool classes.
|
|
|
|
*
|
2014-01-05 12:05:05 +00:00
|
|
|
* @copyright 2011-2014 VisualEditor Team and others; see AUTHORS.txt
|
2013-08-27 23:28:29 +00:00
|
|
|
* @license The MIT License (MIT); see LICENSE.txt
|
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
|
|
|
* MediaWiki UserInterface media edit tool.
|
|
|
|
*
|
|
|
|
* @class
|
|
|
|
* @extends ve.ui.DialogTool
|
|
|
|
* @constructor
|
2013-10-23 23:27:12 +00:00
|
|
|
* @param {OO.ui.ToolGroup} toolGroup
|
2013-09-25 10:21:09 +00:00
|
|
|
* @param {Object} [config] Configuration options
|
2013-08-27 23:28:29 +00:00
|
|
|
*/
|
2013-10-23 23:27:12 +00:00
|
|
|
ve.ui.MWMediaEditDialogTool = function VeUiMWMediaEditDialogTool( toolGroup, config ) {
|
|
|
|
ve.ui.DialogTool.call( this, toolGroup, config );
|
2013-08-27 23:28:29 +00:00
|
|
|
};
|
2013-10-11 21:44:09 +00:00
|
|
|
OO.inheritClass( ve.ui.MWMediaEditDialogTool, ve.ui.DialogTool );
|
2013-08-27 23:28:29 +00:00
|
|
|
ve.ui.MWMediaEditDialogTool.static.name = 'mediaEdit';
|
|
|
|
ve.ui.MWMediaEditDialogTool.static.group = 'object';
|
|
|
|
ve.ui.MWMediaEditDialogTool.static.icon = 'picture';
|
2014-02-12 21:45:37 +00:00
|
|
|
ve.ui.MWMediaEditDialogTool.static.title =
|
|
|
|
OO.ui.deferMsg( 'visualeditor-dialogbutton-media-tooltip' );
|
2013-08-27 23:28:29 +00:00
|
|
|
ve.ui.MWMediaEditDialogTool.static.dialog = 'mediaEdit';
|
|
|
|
ve.ui.MWMediaEditDialogTool.static.modelClasses = [ ve.dm.MWBlockImageNode ];
|
|
|
|
ve.ui.MWMediaEditDialogTool.static.autoAdd = false;
|
|
|
|
ve.ui.toolFactory.register( ve.ui.MWMediaEditDialogTool );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* MediaWiki UserInterface media insert tool.
|
|
|
|
*
|
|
|
|
* @class
|
|
|
|
* @extends ve.ui.DialogTool
|
|
|
|
*
|
|
|
|
* @constructor
|
2013-10-23 23:27:12 +00:00
|
|
|
* @param {OO.ui.ToolGroup} toolGroup
|
2013-09-25 10:21:09 +00:00
|
|
|
* @param {Object} [config] Configuration options
|
2013-08-27 23:28:29 +00:00
|
|
|
*/
|
2013-10-23 23:27:12 +00:00
|
|
|
ve.ui.MWMediaInsertDialogTool = function VeUiMWMediaInsertDialogTool( toolGroup, config ) {
|
|
|
|
ve.ui.DialogTool.call( this, toolGroup, config );
|
2013-08-27 23:28:29 +00:00
|
|
|
};
|
2013-10-11 21:44:09 +00:00
|
|
|
OO.inheritClass( ve.ui.MWMediaInsertDialogTool, ve.ui.DialogTool );
|
2013-08-27 23:28:29 +00:00
|
|
|
ve.ui.MWMediaInsertDialogTool.static.name = 'mediaInsert';
|
|
|
|
ve.ui.MWMediaInsertDialogTool.static.group = 'object';
|
|
|
|
ve.ui.MWMediaInsertDialogTool.static.icon = 'picture';
|
2014-02-12 21:45:37 +00:00
|
|
|
ve.ui.MWMediaInsertDialogTool.static.title =
|
|
|
|
OO.ui.deferMsg( 'visualeditor-dialogbutton-media-tooltip' );
|
2013-08-27 23:28:29 +00:00
|
|
|
ve.ui.MWMediaInsertDialogTool.static.dialog = 'mediaInsert';
|
|
|
|
ve.ui.toolFactory.register( ve.ui.MWMediaInsertDialogTool );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* MediaWiki UserInterface reference tool.
|
|
|
|
*
|
|
|
|
* @class
|
|
|
|
* @extends ve.ui.DialogTool
|
|
|
|
*
|
|
|
|
* @constructor
|
2013-10-23 23:27:12 +00:00
|
|
|
* @param {OO.ui.ToolGroup} toolGroup
|
2013-09-25 10:21:09 +00:00
|
|
|
* @param {Object} [config] Configuration options
|
2013-08-27 23:28:29 +00:00
|
|
|
*/
|
2013-10-23 23:27:12 +00:00
|
|
|
ve.ui.MWReferenceDialogTool = function VeUiMWReferenceDialogTool( toolGroup, config ) {
|
|
|
|
ve.ui.DialogTool.call( this, toolGroup, config );
|
2013-08-27 23:28:29 +00:00
|
|
|
};
|
2013-10-11 21:44:09 +00:00
|
|
|
OO.inheritClass( ve.ui.MWReferenceDialogTool, ve.ui.DialogTool );
|
2013-08-27 23:28:29 +00:00
|
|
|
ve.ui.MWReferenceDialogTool.static.name = 'reference';
|
|
|
|
ve.ui.MWReferenceDialogTool.static.group = 'object';
|
|
|
|
ve.ui.MWReferenceDialogTool.static.icon = 'reference';
|
2014-02-12 21:45:37 +00:00
|
|
|
ve.ui.MWReferenceDialogTool.static.title =
|
|
|
|
OO.ui.deferMsg( 'visualeditor-dialogbutton-reference-tooltip' );
|
2013-08-27 23:28:29 +00:00
|
|
|
ve.ui.MWReferenceDialogTool.static.dialog = 'reference';
|
|
|
|
ve.ui.MWReferenceDialogTool.static.modelClasses = [ ve.dm.MWReferenceNode ];
|
|
|
|
ve.ui.toolFactory.register( ve.ui.MWReferenceDialogTool );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* MediaWiki UserInterface reference list tool.
|
|
|
|
*
|
|
|
|
* @class
|
|
|
|
* @extends ve.ui.DialogTool
|
|
|
|
* @constructor
|
2013-10-23 23:27:12 +00:00
|
|
|
* @param {OO.ui.ToolGroup} toolGroup
|
2013-09-25 10:21:09 +00:00
|
|
|
* @param {Object} [config] Configuration options
|
2013-08-27 23:28:29 +00:00
|
|
|
*/
|
2013-10-23 23:27:12 +00:00
|
|
|
ve.ui.MWReferenceListDialogTool = function VeUiMWReferenceListDialogTool( toolGroup, config ) {
|
|
|
|
ve.ui.DialogTool.call( this, toolGroup, config );
|
2013-08-27 23:28:29 +00:00
|
|
|
};
|
2013-10-11 21:44:09 +00:00
|
|
|
OO.inheritClass( ve.ui.MWReferenceListDialogTool, ve.ui.DialogTool );
|
2013-08-27 23:28:29 +00:00
|
|
|
ve.ui.MWReferenceListDialogTool.static.name = 'referenceList';
|
|
|
|
ve.ui.MWReferenceListDialogTool.static.group = 'object';
|
|
|
|
ve.ui.MWReferenceListDialogTool.static.icon = 'references';
|
2014-02-12 21:45:37 +00:00
|
|
|
ve.ui.MWReferenceListDialogTool.static.title =
|
|
|
|
OO.ui.deferMsg( 'visualeditor-dialogbutton-referencelist-tooltip' );
|
2013-08-27 23:28:29 +00:00
|
|
|
ve.ui.MWReferenceListDialogTool.static.dialog = 'referenceList';
|
|
|
|
ve.ui.MWReferenceListDialogTool.static.modelClasses = [ ve.dm.MWReferenceListNode ];
|
|
|
|
ve.ui.toolFactory.register( ve.ui.MWReferenceListDialogTool );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* MediaWiki UserInterface transclusion tool.
|
|
|
|
*
|
|
|
|
* @class
|
|
|
|
* @extends ve.ui.DialogTool
|
|
|
|
* @constructor
|
2013-10-23 23:27:12 +00:00
|
|
|
* @param {OO.ui.ToolGroup} toolGroup
|
2013-09-25 10:21:09 +00:00
|
|
|
* @param {Object} [config] Configuration options
|
2013-08-27 23:28:29 +00:00
|
|
|
*/
|
2013-10-23 23:27:12 +00:00
|
|
|
ve.ui.MWTransclusionDialogTool = function VeUiMWTransclusionDialogTool( toolGroup, config ) {
|
|
|
|
ve.ui.DialogTool.call( this, toolGroup, config );
|
2013-08-27 23:28:29 +00:00
|
|
|
};
|
2013-10-11 21:44:09 +00:00
|
|
|
OO.inheritClass( ve.ui.MWTransclusionDialogTool, ve.ui.DialogTool );
|
2013-08-27 23:28:29 +00:00
|
|
|
ve.ui.MWTransclusionDialogTool.static.name = 'transclusion';
|
|
|
|
ve.ui.MWTransclusionDialogTool.static.group = 'object';
|
|
|
|
ve.ui.MWTransclusionDialogTool.static.icon = 'template';
|
2014-02-12 21:45:37 +00:00
|
|
|
ve.ui.MWTransclusionDialogTool.static.title =
|
|
|
|
OO.ui.deferMsg( 'visualeditor-dialogbutton-transclusion-tooltip' );
|
2013-08-27 23:28:29 +00:00
|
|
|
ve.ui.MWTransclusionDialogTool.static.dialog = 'transclusion';
|
|
|
|
ve.ui.MWTransclusionDialogTool.static.modelClasses = [ ve.dm.MWTransclusionNode ];
|
|
|
|
ve.ui.toolFactory.register( ve.ui.MWTransclusionDialogTool );
|
|
|
|
|
2013-10-17 17:35:16 +00:00
|
|
|
/**
|
2013-12-19 16:38:02 +00:00
|
|
|
* MediaWiki UserInterface meta dialog tool.
|
2013-10-17 17:35:16 +00:00
|
|
|
*
|
|
|
|
* @class
|
|
|
|
* @extends ve.ui.DialogTool
|
|
|
|
* @constructor
|
|
|
|
* @param {OO.ui.Toolbar} toolbar
|
|
|
|
* @param {Object} [config] Configuration options
|
|
|
|
*/
|
|
|
|
ve.ui.MWMetaDialogTool = function VeUiMWMetaDialogTool( toolbar, config ) {
|
|
|
|
ve.ui.DialogTool.call( this, toolbar, config );
|
|
|
|
};
|
|
|
|
OO.inheritClass( ve.ui.MWMetaDialogTool, ve.ui.DialogTool );
|
|
|
|
ve.ui.MWMetaDialogTool.static.name = 'meta';
|
|
|
|
ve.ui.MWMetaDialogTool.static.group = 'utility';
|
2013-12-19 16:38:02 +00:00
|
|
|
ve.ui.MWMetaDialogTool.static.icon = 'window';
|
2014-02-12 21:45:37 +00:00
|
|
|
ve.ui.MWMetaDialogTool.static.title =
|
|
|
|
OO.ui.deferMsg( 'visualeditor-meta-tool' );
|
2013-10-17 17:35:16 +00:00
|
|
|
ve.ui.MWMetaDialogTool.static.dialog = 'meta';
|
|
|
|
ve.ui.MWMetaDialogTool.static.autoAdd = false;
|
|
|
|
ve.ui.toolFactory.register( ve.ui.MWMetaDialogTool );
|
2013-10-17 22:09:48 +00:00
|
|
|
|
2013-12-19 16:38:02 +00:00
|
|
|
/**
|
|
|
|
* MediaWiki UserInterface page settings tool.
|
|
|
|
*
|
|
|
|
* @class
|
|
|
|
* @extends ve.ui.DialogTool
|
|
|
|
* @constructor
|
|
|
|
* @param {OO.ui.Toolbar} toolbar
|
|
|
|
* @param {Object} [config] Configuration options
|
|
|
|
*/
|
|
|
|
ve.ui.MWPageSettingsDialogTool = function VeUiMWPageSettingsDialogTool( toolbar, config ) {
|
|
|
|
ve.ui.DialogTool.call( this, toolbar, config );
|
|
|
|
};
|
|
|
|
OO.inheritClass( ve.ui.MWPageSettingsDialogTool, ve.ui.DialogTool );
|
|
|
|
ve.ui.MWPageSettingsDialogTool.static.name = 'settings';
|
|
|
|
ve.ui.MWPageSettingsDialogTool.static.group = 'utility';
|
|
|
|
ve.ui.MWPageSettingsDialogTool.static.icon = 'settings';
|
2014-02-12 21:45:37 +00:00
|
|
|
ve.ui.MWPageSettingsDialogTool.static.title =
|
|
|
|
OO.ui.deferMsg( 'visualeditor-settings-tool' );
|
2013-12-19 16:38:02 +00:00
|
|
|
ve.ui.MWPageSettingsDialogTool.static.dialog = 'meta';
|
|
|
|
ve.ui.MWPageSettingsDialogTool.static.config = { 'page': 'settings' };
|
|
|
|
ve.ui.MWPageSettingsDialogTool.static.autoAdd = false;
|
|
|
|
ve.ui.toolFactory.register( ve.ui.MWPageSettingsDialogTool );
|
|
|
|
|
2013-10-17 22:09:48 +00:00
|
|
|
/**
|
|
|
|
* MediaWiki UserInterface categories tool.
|
|
|
|
*
|
|
|
|
* @class
|
|
|
|
* @extends ve.ui.DialogTool
|
|
|
|
* @constructor
|
|
|
|
* @param {OO.ui.Toolbar} toolbar
|
|
|
|
* @param {Object} [config] Configuration options
|
|
|
|
*/
|
|
|
|
ve.ui.MWCategoriesDialogTool = function VeUiMWCategoriesDialogTool( toolbar, config ) {
|
|
|
|
ve.ui.DialogTool.call( this, toolbar, config );
|
|
|
|
};
|
|
|
|
OO.inheritClass( ve.ui.MWCategoriesDialogTool, ve.ui.DialogTool );
|
|
|
|
ve.ui.MWCategoriesDialogTool.static.name = 'categories';
|
|
|
|
ve.ui.MWCategoriesDialogTool.static.group = 'utility';
|
|
|
|
ve.ui.MWCategoriesDialogTool.static.icon = 'tag';
|
2014-02-12 21:45:37 +00:00
|
|
|
ve.ui.MWCategoriesDialogTool.static.title =
|
|
|
|
OO.ui.deferMsg( 'visualeditor-categories-tool' );
|
2013-10-17 22:09:48 +00:00
|
|
|
ve.ui.MWCategoriesDialogTool.static.dialog = 'meta';
|
|
|
|
ve.ui.MWCategoriesDialogTool.static.config = { 'page': 'categories' };
|
|
|
|
ve.ui.MWCategoriesDialogTool.static.autoAdd = false;
|
|
|
|
ve.ui.toolFactory.register( ve.ui.MWCategoriesDialogTool );
|
|
|
|
|
|
|
|
/**
|
|
|
|
* MediaWiki UserInterface languages tool.
|
|
|
|
*
|
|
|
|
* @class
|
|
|
|
* @extends ve.ui.DialogTool
|
|
|
|
* @constructor
|
|
|
|
* @param {OO.ui.Toolbar} toolbar
|
|
|
|
* @param {Object} [config] Configuration options
|
|
|
|
*/
|
|
|
|
ve.ui.MWLanguagesDialogTool = function VeUiMWLanguagesDialogTool( toolbar, config ) {
|
|
|
|
ve.ui.DialogTool.call( this, toolbar, config );
|
|
|
|
};
|
|
|
|
OO.inheritClass( ve.ui.MWLanguagesDialogTool, ve.ui.DialogTool );
|
|
|
|
ve.ui.MWLanguagesDialogTool.static.name = 'languages';
|
|
|
|
ve.ui.MWLanguagesDialogTool.static.group = 'utility';
|
|
|
|
ve.ui.MWLanguagesDialogTool.static.icon = 'language';
|
2014-02-12 21:45:37 +00:00
|
|
|
ve.ui.MWLanguagesDialogTool.static.title =
|
|
|
|
OO.ui.deferMsg( 'visualeditor-languages-tool' );
|
2013-10-17 22:09:48 +00:00
|
|
|
ve.ui.MWLanguagesDialogTool.static.dialog = 'meta';
|
|
|
|
ve.ui.MWLanguagesDialogTool.static.config = { 'page': 'languages' };
|
|
|
|
ve.ui.MWLanguagesDialogTool.static.autoAdd = false;
|
|
|
|
ve.ui.toolFactory.register( ve.ui.MWLanguagesDialogTool );
|
2014-01-13 14:56:49 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* MediaWiki UserInterface command help tool.
|
|
|
|
*
|
|
|
|
* @class
|
|
|
|
* @extends ve.ui.DialogTool
|
|
|
|
* @constructor
|
|
|
|
* @param {OO.ui.Toolbar} toolbar
|
|
|
|
* @param {Object} [config] Configuration options
|
|
|
|
*/
|
|
|
|
ve.ui.MWCommandHelpDialogTool = function VeUiMWCommandHelpDialogTool( toolbar, config ) {
|
|
|
|
ve.ui.DialogTool.call( this, toolbar, config );
|
|
|
|
};
|
|
|
|
OO.inheritClass( ve.ui.MWCommandHelpDialogTool, ve.ui.DialogTool );
|
|
|
|
ve.ui.MWCommandHelpDialogTool.static.name = 'commandHelp';
|
|
|
|
ve.ui.MWCommandHelpDialogTool.static.group = 'utility';
|
|
|
|
ve.ui.MWCommandHelpDialogTool.static.icon = 'help';
|
2014-02-12 21:45:37 +00:00
|
|
|
ve.ui.MWCommandHelpDialogTool.static.title =
|
|
|
|
OO.ui.deferMsg( 'visualeditor-dialog-command-help-title' );
|
2014-01-13 14:56:49 +00:00
|
|
|
ve.ui.MWCommandHelpDialogTool.static.dialog = 'commandHelp';
|
|
|
|
ve.ui.MWCommandHelpDialogTool.static.autoAdd = false;
|
|
|
|
ve.ui.toolFactory.register( ve.ui.MWCommandHelpDialogTool );
|