2012-03-06 22:31:44 +00:00
|
|
|
/**
|
2012-03-06 22:39:43 +00:00
|
|
|
* Creates an ve.ce.PreNode object.
|
2012-03-06 22:31:44 +00:00
|
|
|
*
|
|
|
|
* @class
|
|
|
|
* @constructor
|
2012-03-06 22:39:43 +00:00
|
|
|
* @extends {ve.ce.LeafNode}
|
2012-03-06 22:31:44 +00:00
|
|
|
* @param {ve.dm.PreNode} model Pre model to view
|
|
|
|
*/
|
2012-03-06 22:39:43 +00:00
|
|
|
ve.ce.PreNode = function( model ) {
|
2012-03-06 22:31:44 +00:00
|
|
|
// Inheritance
|
2012-03-06 22:39:43 +00:00
|
|
|
ve.ce.LeafNode.call( this, model, undefined, { 'pre': true } );
|
2012-03-06 22:31:44 +00:00
|
|
|
|
|
|
|
// DOM Changes
|
|
|
|
this.$.addClass( 'es-preView' );
|
|
|
|
};
|
|
|
|
|
|
|
|
/* Registration */
|
|
|
|
|
2012-03-06 22:39:43 +00:00
|
|
|
ve.ce.DocumentNode.splitRules.pre = {
|
2012-03-06 22:31:44 +00:00
|
|
|
'self': true,
|
|
|
|
'children': null
|
|
|
|
};
|
|
|
|
|
|
|
|
/* Inheritance */
|
|
|
|
|
2012-03-06 22:39:43 +00:00
|
|
|
ve.extendClass( ve.ce.PreNode, ve.ce.LeafNode );
|