diff options
Diffstat (limited to 'src/3rdparty/webkit/WebCore/rendering/RenderTableCol.cpp')
-rw-r--r-- | src/3rdparty/webkit/WebCore/rendering/RenderTableCol.cpp | 23 |
1 files changed, 18 insertions, 5 deletions
diff --git a/src/3rdparty/webkit/WebCore/rendering/RenderTableCol.cpp b/src/3rdparty/webkit/WebCore/rendering/RenderTableCol.cpp index f17963c..d9a4172 100644 --- a/src/3rdparty/webkit/WebCore/rendering/RenderTableCol.cpp +++ b/src/3rdparty/webkit/WebCore/rendering/RenderTableCol.cpp @@ -75,11 +75,8 @@ IntRect RenderTableCol::clippedOverflowRectForRepaint(RenderBoxModelObject* repa // FIXME: Find a better way to do this, e.g., need to repaint all the cells that we // might have propagated a background color or borders into. // FIXME: check for repaintContainer each time here? - RenderObject* table = parent(); - if (table && !table->isTable()) - table = table->parent(); - if (table && table->isTable()) - return table->clippedOverflowRectForRepaint(repaintContainer); + if (RenderObject* parentTable = table()) + return parentTable->clippedOverflowRectForRepaint(repaintContainer); return IntRect(); } @@ -90,4 +87,20 @@ void RenderTableCol::imageChanged(WrappedImagePtr, const IntRect*) repaint(); } +void RenderTableCol::calcPrefWidths() +{ + setPrefWidthsDirty(false); + + for (RenderObject* child = firstChild(); child; child = child->nextSibling()) + child->setPrefWidthsDirty(false); +} + +RenderTable* RenderTableCol::table() const +{ + RenderObject* table = parent(); + if (table && !table->isTable()) + table = table->parent(); + return table && table->isTable() ? static_cast<RenderTable*>(table) : 0; +} + } |