Column alignment for grid

This commit is contained in:
Nathan Gray 2012-03-28 18:57:37 +00:00
parent a46264ace3
commit d61a9f4a69

View File

@ -314,6 +314,11 @@ var et2_grid = et2_DOMWidget.extend([et2_IDetachedDOM], {
var span = cell.colSpan = this._forceNumber(cell.colSpan);
// Read the align value of the element
if (node.getAttribute("align"))
{
cell.align = node.getAttribute("align");
}
// Create the element
var widget = this.createElementFromNode(node, nodeName);
@ -512,6 +517,11 @@ var et2_grid = et2_DOMWidget.extend([et2_IDetachedDOM], {
td.width(cell.width);
}
if (cell.align)
{
td.attr("align",cell.align);
}
// Add the entry for the widget to the management array
this.managementArray.push({
"cell": td[0],