2012-03-06 22:31:44 +00:00
|
|
|
/**
|
2012-03-06 22:39:43 +00:00
|
|
|
* Creates an ve.ce.TableNode object.
|
2012-03-06 22:31:44 +00:00
|
|
|
*
|
|
|
|
* @class
|
|
|
|
* @constructor
|
2012-03-06 22:39:43 +00:00
|
|
|
* @extends {ve.ce.BranchNode}
|
2012-03-06 22:31:44 +00:00
|
|
|
* @param {ve.dm.TableNode} model Table model to view
|
|
|
|
*/
|
2012-03-06 22:39:43 +00:00
|
|
|
ve.ce.TableNode = function( model ) {
|
2012-03-06 22:31:44 +00:00
|
|
|
// Inheritance
|
2012-03-06 22:39:43 +00:00
|
|
|
ve.ce.BranchNode.call( this, model, $( '<table>' ) );
|
2012-03-06 22:31:44 +00:00
|
|
|
|
|
|
|
// DOM Changes
|
|
|
|
this.$
|
|
|
|
.attr( 'style', model.getElementAttribute( 'html/style' ) )
|
|
|
|
.addClass( 'es-tableView' );
|
|
|
|
};
|
|
|
|
|
|
|
|
/* Registration */
|
|
|
|
|
2012-03-06 22:39:43 +00:00
|
|
|
ve.ce.DocumentNode.splitRules.table = {
|
2012-03-06 22:31:44 +00:00
|
|
|
'self': false,
|
|
|
|
'children': false
|
|
|
|
};
|
|
|
|
|
|
|
|
/* Inheritance */
|
|
|
|
|
2012-03-06 22:39:43 +00:00
|
|
|
ve.extendClass( ve.ce.TableNode, ve.ce.BranchNode );
|