2013-07-03 21:44:15 +00:00
|
|
|
/*!
|
|
|
|
* VisualEditor UserInterface MWMathButtonTool class.
|
|
|
|
*
|
|
|
|
* @copyright 2011-2013 VisualEditor Team and others; see AUTHORS.txt
|
|
|
|
* @license The MIT License (MIT); see LICENSE.txt
|
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
2013-07-26 11:04:19 +00:00
|
|
|
* UserInterface MediaWiki math button tool.
|
2013-07-03 21:44:15 +00:00
|
|
|
*
|
|
|
|
* @class
|
|
|
|
* @extends ve.ui.InspectorButtonTool
|
|
|
|
* @constructor
|
|
|
|
* @param {ve.ui.Toolbar} toolbar
|
|
|
|
* @param {Object} [config] Config options
|
|
|
|
*/
|
|
|
|
ve.ui.MWMathButtonTool = function VeUiMWMathButtonTool( toolbar, config ) {
|
|
|
|
// Parent constructor
|
|
|
|
ve.ui.InspectorButtonTool.call( this, toolbar, config );
|
|
|
|
};
|
|
|
|
|
|
|
|
/* Inheritance */
|
|
|
|
|
|
|
|
ve.inheritClass( ve.ui.MWMathButtonTool, ve.ui.InspectorButtonTool );
|
|
|
|
|
|
|
|
/* Static Properties */
|
|
|
|
|
|
|
|
ve.ui.MWMathButtonTool.static.name = 'mwMath';
|
2013-07-19 22:30:29 +00:00
|
|
|
|
2013-07-19 00:28:39 +00:00
|
|
|
ve.ui.MWMathButtonTool.static.icon = 'math';
|
2013-07-19 22:30:29 +00:00
|
|
|
|
2013-07-03 21:44:15 +00:00
|
|
|
ve.ui.MWMathButtonTool.static.titleMessage = 'visualeditor-mwmathinspector-title';
|
2013-07-19 22:30:29 +00:00
|
|
|
|
2013-07-03 21:44:15 +00:00
|
|
|
ve.ui.MWMathButtonTool.static.inspector = 'mwMathInspector';
|
2013-07-19 22:30:29 +00:00
|
|
|
|
2013-07-03 21:44:15 +00:00
|
|
|
ve.ui.MWMathButtonTool.static.modelClasses = [ ve.dm.MWMathNode ];
|
|
|
|
|
|
|
|
/* Registration */
|
|
|
|
|
|
|
|
ve.ui.toolFactory.register( 'mwMath', ve.ui.MWMathButtonTool );
|