Tables in the main part of hbox need to be inline, or the block display ruins layout. Maybe a better way for this though

This commit is contained in:
Nathan Gray 2012-07-23 18:00:31 +00:00
parent 6c53a6f067
commit b5b98f9a8b

View File

@ -161,6 +161,17 @@ var et2_hbox = et2_baseWidget.extend({
// Normally simply return the hbox-div
return this._super.apply(this, arguments);
},
/**
* Tables added to the root node need to be inline instead of blocks
*/
addChild: function(child) {
this._super.apply(this, arguments);
if(child.instanceOf && child.instanceOf(et2_grid) || child._type == 'et2_grid')
{
jQuery(child.getDOMNode(child)).css("display", "inline-table");
}
}
});