mediawiki-extensions-Visual.../modules/ve-mw/dm/ve.dm.MWWikitextSurface.js
James D. Forrester 3c293ea00c doc: Bump copyright year for 2019
Change-Id: I8991b97c980d4149f53eb5601036220ef3c0c440
2019-01-01 13:24:23 +00:00

32 lines
811 B
JavaScript

/*!
* VisualEditor DataModel Surface class.
*
* @copyright 2011-2019 VisualEditor Team and others; see http://ve.mit-license.org
*/
/**
* DataModel surface.
*
* @class
* @extends ve.dm.Surface
*
* @constructor
* @param {ve.dm.Document} doc
* @param {Object} [config]
*/
ve.dm.MWWikitextSurface = function VeDmMwWikitextSurface( doc, config ) {
// Parent constructors
ve.dm.MWWikitextSurface.super.call( this, doc, ve.extendObject( config, { sourceMode: true } ) );
};
/* Inheritance */
OO.inheritClass( ve.dm.MWWikitextSurface, ve.dm.Surface );
/**
* @inheritdoc
*/
ve.dm.MWWikitextSurface.prototype.getFragment = function ( selection, noAutoSelect, excludeInsertions ) {
return new ve.dm.MWWikitextSurfaceFragment( this, selection || this.selection, noAutoSelect, excludeInsertions );
};