<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[182701] releases/WebKitGTK/webkit-2.8/Source/WebCore</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/182701">182701</a></dd>
<dt>Author</dt> <dd>carlosgc@webkit.org</dd>
<dt>Date</dt> <dd>2015-04-13 03:29:23 -0700 (Mon, 13 Apr 2015)</dd>
</dl>

<h3>Log Message</h3>
<pre>Merge <a href="http://trac.webkit.org/projects/webkit/changeset/180241">r180241</a> - Minor RenderTable* class cleanups.
https://bugs.webkit.org/show_bug.cgi?id=141707

Reviewed by Andreas Kling.

Use in-class initializer where possible.
Remove redundant code.
Move multiline implementations out of class declaration.

No change in functionality.

* rendering/RenderTableCaption.cpp:
(WebCore::RenderTableCaption::insertedIntoTree):
(WebCore::RenderTableCaption::willBeRemovedFromTree):
(WebCore::RenderTableCaption::containingBlockLogicalWidthForContent): Deleted.
* rendering/RenderTableCaption.h:
* rendering/RenderTableCell.cpp:
(WebCore::RenderTableCell::RenderTableCell):
* rendering/RenderTableCell.h:
(WebCore::RenderTableCell::colSpan):
(WebCore::RenderTableCell::rowSpan):
(WebCore::RenderTableCell::setCol):
(WebCore::RenderTableCell::col):
(WebCore::RenderTableCell::section):
(WebCore::RenderTableCell::table):
(WebCore::RenderTableCell::rowIndex):
(WebCore::RenderTableCell::styleOrColLogicalWidth):
(WebCore::RenderTableCell::logicalHeightForRowSizing):
(WebCore::RenderTableCell::isBaselineAligned):
(WebCore::RenderTableCell::borderAdjoiningTableStart):
(WebCore::RenderTableCell::borderAdjoiningTableEnd):
(WebCore::RenderTableCell::borderAdjoiningCellBefore):
(WebCore::RenderTableCell::borderAdjoiningCellAfter):
* rendering/RenderTableCol.cpp:
(WebCore::RenderTableCol::RenderTableCol):
* rendering/RenderTableCol.h:
(WebCore::RenderTableCol::enclosingColumnGroupIfAdjacentBefore):
(WebCore::RenderTableCol::enclosingColumnGroupIfAdjacentAfter):
* rendering/RenderTableRow.h:
(WebCore::RenderTableRow::setRowIndex):
(WebCore::RenderTableRow::rowIndex):
(WebCore::RenderTableRow::borderAdjoiningTableStart):
(WebCore::RenderTableRow::borderAdjoiningTableEnd):
(WebCore::RenderTableRow::table):
(WebCore::RenderTableSection::firstRow):
(WebCore::RenderTableSection::lastRow):
* rendering/RenderTableSection.cpp:
(WebCore::RenderTableSection::RenderTableSection):
(WebCore::RenderTableSection::dirtiedRows):
(WebCore::RenderTableSection::dirtiedColumns):
(WebCore::RenderTableSection::paintObject):
(WebCore::RenderTableSection::nodeAtPoint):
* rendering/RenderTableSection.h:
(WebCore::CellSpan::CellSpan):
(WebCore::RenderTableSection::borderAdjoiningTableStart):
(WebCore::RenderTableSection::borderAdjoiningTableEnd):
(WebCore::RenderTableSection::cellAt):
(WebCore::RenderTableSection::primaryCellAt):
(WebCore::RenderTableSection::rowRendererAt):
(WebCore::RenderTableSection::outerBorderLeft):
(WebCore::RenderTableSection::outerBorderRight):
(WebCore::RenderTableSection::outerBorderTop):
(WebCore::RenderTableSection::outerBorderBottom):
(WebCore::RenderTableSection::numRows):
(WebCore::RenderTableSection::recalcCellsIfNeeded):
(WebCore::RenderTableSection::rowBaseline):
(WebCore::RenderTableSection::fullTableRowSpan):
(WebCore::CellSpan::start): Deleted.
(WebCore::CellSpan::end): Deleted.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#releasesWebKitGTKwebkit28SourceWebCoreChangeLog">releases/WebKitGTK/webkit-2.8/Source/WebCore/ChangeLog</a></li>
<li><a href="#releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableCaptioncpp">releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCaption.cpp</a></li>
<li><a href="#releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableCaptionh">releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCaption.h</a></li>
<li><a href="#releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableCellcpp">releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCell.cpp</a></li>
<li><a href="#releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableCellh">releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCell.h</a></li>
<li><a href="#releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableColcpp">releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCol.cpp</a></li>
<li><a href="#releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableColh">releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCol.h</a></li>
<li><a href="#releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableRowh">releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableRow.h</a></li>
<li><a href="#releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableSectioncpp">releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableSection.cpp</a></li>
<li><a href="#releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableSectionh">releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableSection.h</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="releasesWebKitGTKwebkit28SourceWebCoreChangeLog"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.8/Source/WebCore/ChangeLog (182700 => 182701)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/Source/WebCore/ChangeLog        2015-04-13 10:27:52 UTC (rev 182700)
+++ releases/WebKitGTK/webkit-2.8/Source/WebCore/ChangeLog        2015-04-13 10:29:23 UTC (rev 182701)
</span><span class="lines">@@ -1,3 +1,75 @@
</span><ins>+2015-02-17  Zalan Bujtas  &lt;zalan@apple.com&gt;
+
+        Minor RenderTable* class cleanups.
+        https://bugs.webkit.org/show_bug.cgi?id=141707
+
+        Reviewed by Andreas Kling.
+
+        Use in-class initializer where possible.
+        Remove redundant code.
+        Move multiline implementations out of class declaration.
+
+        No change in functionality.
+
+        * rendering/RenderTableCaption.cpp:
+        (WebCore::RenderTableCaption::insertedIntoTree):
+        (WebCore::RenderTableCaption::willBeRemovedFromTree):
+        (WebCore::RenderTableCaption::containingBlockLogicalWidthForContent): Deleted.
+        * rendering/RenderTableCaption.h:
+        * rendering/RenderTableCell.cpp:
+        (WebCore::RenderTableCell::RenderTableCell):
+        * rendering/RenderTableCell.h:
+        (WebCore::RenderTableCell::colSpan):
+        (WebCore::RenderTableCell::rowSpan):
+        (WebCore::RenderTableCell::setCol):
+        (WebCore::RenderTableCell::col):
+        (WebCore::RenderTableCell::section):
+        (WebCore::RenderTableCell::table):
+        (WebCore::RenderTableCell::rowIndex):
+        (WebCore::RenderTableCell::styleOrColLogicalWidth):
+        (WebCore::RenderTableCell::logicalHeightForRowSizing):
+        (WebCore::RenderTableCell::isBaselineAligned):
+        (WebCore::RenderTableCell::borderAdjoiningTableStart):
+        (WebCore::RenderTableCell::borderAdjoiningTableEnd):
+        (WebCore::RenderTableCell::borderAdjoiningCellBefore):
+        (WebCore::RenderTableCell::borderAdjoiningCellAfter):
+        * rendering/RenderTableCol.cpp:
+        (WebCore::RenderTableCol::RenderTableCol):
+        * rendering/RenderTableCol.h:
+        (WebCore::RenderTableCol::enclosingColumnGroupIfAdjacentBefore):
+        (WebCore::RenderTableCol::enclosingColumnGroupIfAdjacentAfter):
+        * rendering/RenderTableRow.h:
+        (WebCore::RenderTableRow::setRowIndex):
+        (WebCore::RenderTableRow::rowIndex):
+        (WebCore::RenderTableRow::borderAdjoiningTableStart):
+        (WebCore::RenderTableRow::borderAdjoiningTableEnd):
+        (WebCore::RenderTableRow::table):
+        (WebCore::RenderTableSection::firstRow):
+        (WebCore::RenderTableSection::lastRow):
+        * rendering/RenderTableSection.cpp:
+        (WebCore::RenderTableSection::RenderTableSection):
+        (WebCore::RenderTableSection::dirtiedRows):
+        (WebCore::RenderTableSection::dirtiedColumns):
+        (WebCore::RenderTableSection::paintObject):
+        (WebCore::RenderTableSection::nodeAtPoint):
+        * rendering/RenderTableSection.h:
+        (WebCore::CellSpan::CellSpan):
+        (WebCore::RenderTableSection::borderAdjoiningTableStart):
+        (WebCore::RenderTableSection::borderAdjoiningTableEnd):
+        (WebCore::RenderTableSection::cellAt):
+        (WebCore::RenderTableSection::primaryCellAt):
+        (WebCore::RenderTableSection::rowRendererAt):
+        (WebCore::RenderTableSection::outerBorderLeft):
+        (WebCore::RenderTableSection::outerBorderRight):
+        (WebCore::RenderTableSection::outerBorderTop):
+        (WebCore::RenderTableSection::outerBorderBottom):
+        (WebCore::RenderTableSection::numRows):
+        (WebCore::RenderTableSection::recalcCellsIfNeeded):
+        (WebCore::RenderTableSection::rowBaseline):
+        (WebCore::RenderTableSection::fullTableRowSpan):
+        (WebCore::CellSpan::start): Deleted.
+        (WebCore::CellSpan::end): Deleted.
+
</ins><span class="cx"> 2015-04-01  Carlos Alberto Lopez Perez  &lt;clopez@igalia.com&gt;
</span><span class="cx"> 
</span><span class="cx">         [CMake][GTK] Use the right variable to include the Wayland headers.
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableCaptioncpp"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCaption.cpp (182700 => 182701)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCaption.cpp        2015-04-13 10:27:52 UTC (rev 182700)
+++ releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCaption.cpp        2015-04-13 10:29:23 UTC (rev 182701)
</span><span class="lines">@@ -33,23 +33,15 @@
</span><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-LayoutUnit RenderTableCaption::containingBlockLogicalWidthForContent() const
-{
-    RenderBlock* cb = containingBlock();
-    return cb-&gt;logicalWidth();
-}
-
</del><span class="cx"> void RenderTableCaption::insertedIntoTree()
</span><span class="cx"> {
</span><span class="cx">     RenderBlockFlow::insertedIntoTree();
</span><del>-
</del><span class="cx">     table()-&gt;addCaption(this);
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> void RenderTableCaption::willBeRemovedFromTree()
</span><span class="cx"> {
</span><span class="cx">     RenderBlockFlow::willBeRemovedFromTree();
</span><del>-
</del><span class="cx">     table()-&gt;removeCaption(this);
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableCaptionh"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCaption.h (182700 => 182701)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCaption.h        2015-04-13 10:27:52 UTC (rev 182700)
+++ releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCaption.h        2015-04-13 10:29:23 UTC (rev 182701)
</span><span class="lines">@@ -33,7 +33,7 @@
</span><span class="cx"> 
</span><span class="cx">     Element&amp; element() const { return downcast&lt;Element&gt;(nodeForNonAnonymous()); }
</span><span class="cx"> 
</span><del>-    virtual LayoutUnit containingBlockLogicalWidthForContent() const override;
</del><ins>+    virtual LayoutUnit containingBlockLogicalWidthForContent() const override { return containingBlock()-&gt;logicalWidth(); }
</ins><span class="cx">     
</span><span class="cx"> private:
</span><span class="cx">     virtual bool isTableCaption() const override { return true; }
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableCellcpp"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCell.cpp (182700 => 182701)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCell.cpp        2015-04-13 10:27:52 UTC (rev 182700)
+++ releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCell.cpp        2015-04-13 10:29:23 UTC (rev 182701)
</span><span class="lines">@@ -58,8 +58,8 @@
</span><span class="cx">     : RenderBlockFlow(element, WTF::move(style))
</span><span class="cx">     , m_column(unsetColumnIndex)
</span><span class="cx">     , m_cellWidthChanged(false)
</span><del>-    , m_intrinsicPaddingBefore(0)
-    , m_intrinsicPaddingAfter(0)
</del><ins>+    , m_hasColSpan(false)
+    , m_hasRowSpan(false)
</ins><span class="cx"> {
</span><span class="cx">     // We only update the flags when notified of DOM changes in colSpanOrRowSpanChanged()
</span><span class="cx">     // so we need to set their initial values here in case something asks for colSpan()/rowSpan() before then.
</span><span class="lines">@@ -72,8 +72,6 @@
</span><span class="cx">     , m_cellWidthChanged(false)
</span><span class="cx">     , m_hasColSpan(false)
</span><span class="cx">     , m_hasRowSpan(false)
</span><del>-    , m_intrinsicPaddingBefore(0)
-    , m_intrinsicPaddingAfter(0)
</del><span class="cx"> {
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableCellh"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCell.h (182700 => 182701)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCell.h        2015-04-13 10:27:52 UTC (rev 182700)
+++ releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCell.h        2015-04-13 10:29:23 UTC (rev 182701)
</span><span class="lines">@@ -41,85 +41,25 @@
</span><span class="cx">     RenderTableCell(Element&amp;, Ref&lt;RenderStyle&gt;&amp;&amp;);
</span><span class="cx">     RenderTableCell(Document&amp;, Ref&lt;RenderStyle&gt;&amp;&amp;);
</span><span class="cx">     
</span><del>-    unsigned colSpan() const
-    {
-        if (!m_hasColSpan)
-            return 1;
-        return parseColSpanFromDOM();
-    }
-    unsigned rowSpan() const
-    {
-        if (!m_hasRowSpan)
-            return 1;
-        return parseRowSpanFromDOM();
-    }
</del><ins>+    unsigned colSpan() const;
+    unsigned rowSpan() const;
</ins><span class="cx"> 
</span><span class="cx">     // Called from HTMLTableCellElement.
</span><span class="cx">     void colSpanOrRowSpanChanged();
</span><span class="cx"> 
</span><del>-    void setCol(unsigned column)
-    {
-        if (UNLIKELY(column &gt; maxColumnIndex))
-            CRASH();
</del><ins>+    void setCol(unsigned column);
+    unsigned col() const;
</ins><span class="cx"> 
</span><del>-        m_column = column;
-    }
-
-    unsigned col() const
-    {
-        ASSERT(m_column != unsetColumnIndex);
-        return m_column;
-    }
-
</del><span class="cx">     RenderTableCell* nextCell() const;
</span><span class="cx">     RenderTableCell* previousCell() const;
</span><span class="cx"> 
</span><span class="cx">     RenderTableRow* row() const { return downcast&lt;RenderTableRow&gt;(parent()); }
</span><del>-    RenderTableSection* section() const
-    {
-        RenderTableRow* row = this-&gt;row();
-        if (!row)
-            return nullptr;
-        return downcast&lt;RenderTableSection&gt;(row-&gt;parent());
-    }
-    RenderTable* table() const
-    {
-        RenderTableSection* section = this-&gt;section();
-        if (!section)
-            return nullptr;
-        return downcast&lt;RenderTable&gt;(section-&gt;parent());
-    }
</del><ins>+    RenderTableSection* section() const;
+    RenderTable* table() const;
+    unsigned rowIndex() const;
+    Length styleOrColLogicalWidth() const;
+    int logicalHeightForRowSizing() const;
</ins><span class="cx"> 
</span><del>-    unsigned rowIndex() const
-    {
-        // This function shouldn't be called on a detached cell.
-        ASSERT(row());
-        return row()-&gt;rowIndex();
-    }
-
-    Length styleOrColLogicalWidth() const
-    {
-        Length styleWidth = style().logicalWidth();
-        if (!styleWidth.isAuto())
-            return styleWidth;
-        if (RenderTableCol* firstColumn = table()-&gt;colElement(col()))
-            return logicalWidthFromColumns(firstColumn, styleWidth);
-        return styleWidth;
-    }
-
-    int logicalHeightForRowSizing() const
-    {
-        // FIXME: This function does too much work, and is very hot during table layout!
-        int adjustedLogicalHeight = pixelSnappedLogicalHeight() - (intrinsicPaddingBefore() + intrinsicPaddingAfter());
-        int styleLogicalHeight = valueForLength(style().logicalHeight(), 0);
-        // In strict mode, box-sizing: content-box do the right thing and actually add in the border and padding.
-        // Call computedCSSPadding* directly to avoid including implicitPadding.
-        if (!document().inQuirksMode() &amp;&amp; style().boxSizing() != BORDER_BOX)
-            styleLogicalHeight += (computedCSSPaddingBefore() + computedCSSPaddingAfter()).floor() + (borderBefore() + borderAfter()).floor();
-        return std::max(styleLogicalHeight, adjustedLogicalHeight);
-    }
-
-
</del><span class="cx">     void setCellLogicalWidth(int constrainedLogicalWidth);
</span><span class="cx"> 
</span><span class="cx">     virtual LayoutUnit borderLeft() const override;
</span><span class="lines">@@ -142,11 +82,7 @@
</span><span class="cx">     void paintBackgroundsBehindCell(PaintInfo&amp;, const LayoutPoint&amp;, RenderElement* backgroundObject);
</span><span class="cx"> 
</span><span class="cx">     LayoutUnit cellBaselinePosition() const;
</span><del>-    bool isBaselineAligned() const 
-    { 
-        EVerticalAlign va = style().verticalAlign();
-        return va == BASELINE || va == TEXT_BOTTOM || va == TEXT_TOP || va == SUPER || va == SUB || va == LENGTH; 
-    }
</del><ins>+    bool isBaselineAligned() const;
</ins><span class="cx"> 
</span><span class="cx">     void computeIntrinsicPadding(int rowHeight);
</span><span class="cx">     void clearIntrinsicPadding() { setIntrinsicPadding(0, 0); }
</span><span class="lines">@@ -173,60 +109,23 @@
</span><span class="cx">     void setCellWidthChanged(bool b = true) { m_cellWidthChanged = b; }
</span><span class="cx"> 
</span><span class="cx">     static RenderTableCell* createAnonymousWithParentRenderer(const RenderObject*);
</span><del>-    virtual RenderBox* createAnonymousBoxWithSameTypeAs(const RenderObject* parent) const override
-    {
-        return createAnonymousWithParentRenderer(parent);
-    }
</del><ins>+    virtual RenderBox* createAnonymousBoxWithSameTypeAs(const RenderObject* parent) const override { return createAnonymousWithParentRenderer(parent); }
</ins><span class="cx"> 
</span><span class="cx">     // This function is used to unify which table part's style we use for computing direction and
</span><span class="cx">     // writing mode. Writing modes are not allowed on row group and row but direction is.
</span><span class="cx">     // This means we can safely use the same style in all cases to simplify our code.
</span><span class="cx">     // FIXME: Eventually this function should replaced by style() once we support direction
</span><span class="cx">     // on all table parts and writing-mode on cells.
</span><del>-    const RenderStyle&amp; styleForCellFlow() const
-    {
-        return row()-&gt;style();
-    }
</del><ins>+    const RenderStyle&amp; styleForCellFlow() const { return row()-&gt;style(); }
</ins><span class="cx"> 
</span><del>-    const BorderValue&amp; borderAdjoiningTableStart() const
-    {
-        ASSERT(isFirstOrLastCellInRow());
-        if (section()-&gt;hasSameDirectionAs(table()))
-            return style().borderStart();
</del><ins>+    const BorderValue&amp; borderAdjoiningTableStart() const;
+    const BorderValue&amp; borderAdjoiningTableEnd() const;
+    const BorderValue&amp; borderAdjoiningCellBefore(const RenderTableCell*);
+    const BorderValue&amp; borderAdjoiningCellAfter(const RenderTableCell*);
</ins><span class="cx"> 
</span><del>-        return style().borderEnd();
-    }
-
-    const BorderValue&amp; borderAdjoiningTableEnd() const
-    {
-        ASSERT(isFirstOrLastCellInRow());
-        if (section()-&gt;hasSameDirectionAs(table()))
-            return style().borderEnd();
-
-        return style().borderStart();
-    }
-
-    const BorderValue&amp; borderAdjoiningCellBefore(const RenderTableCell* cell)
-    {
-        ASSERT_UNUSED(cell, table()-&gt;cellAfter(cell) == this);
-        // FIXME: https://webkit.org/b/79272 - Add support for mixed directionality at the cell level.
-        return style().borderStart();
-    }
-
-    const BorderValue&amp; borderAdjoiningCellAfter(const RenderTableCell* cell)
-    {
-        ASSERT_UNUSED(cell, table()-&gt;cellBefore(cell) == this);
-        // FIXME: https://webkit.org/b/79272 - Add support for mixed directionality at the cell level.
-        return style().borderEnd();
-    }
-
</del><span class="cx">     using RenderBlockFlow::nodeAtPoint;
</span><del>-
</del><span class="cx"> #ifndef NDEBUG
</span><del>-    bool isFirstOrLastCellInRow() const
-    {
-        return !table()-&gt;cellAfter(this) || !table()-&gt;cellBefore(this);
-    }
</del><ins>+    bool isFirstOrLastCellInRow() const { return !table()-&gt;cellAfter(this) || !table()-&gt;cellBefore(this); }
</ins><span class="cx"> #endif
</span><span class="cx">     
</span><span class="cx">     virtual LayoutRect clippedOverflowRectForRepaint(const RenderLayerModelObject* repaintContainer) const override;
</span><span class="lines">@@ -304,8 +203,8 @@
</span><span class="cx">     unsigned m_cellWidthChanged : 1;
</span><span class="cx">     unsigned m_hasColSpan: 1;
</span><span class="cx">     unsigned m_hasRowSpan: 1;
</span><del>-    int m_intrinsicPaddingBefore;
-    int m_intrinsicPaddingAfter;
</del><ins>+    int m_intrinsicPaddingBefore { 0 };
+    int m_intrinsicPaddingAfter { 0 };
</ins><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> inline RenderTableCell* RenderTableCell::nextCell() const
</span><span class="lines">@@ -318,6 +217,116 @@
</span><span class="cx">     return downcast&lt;RenderTableCell&gt;(RenderBlockFlow::previousSibling());
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+inline unsigned RenderTableCell::colSpan() const
+{
+    if (!m_hasColSpan)
+        return 1;
+    return parseColSpanFromDOM();
+}
+
+inline unsigned RenderTableCell::rowSpan() const
+{
+    if (!m_hasRowSpan)
+        return 1;
+    return parseRowSpanFromDOM();
+}
+
+inline void RenderTableCell::setCol(unsigned column)
+{
+    if (UNLIKELY(column &gt; maxColumnIndex))
+        CRASH();
+    m_column = column;
+}
+
+inline unsigned RenderTableCell::col() const
+{
+    ASSERT(m_column != unsetColumnIndex);
+    return m_column;
+}
+
+inline RenderTableSection* RenderTableCell::section() const
+{
+    RenderTableRow* row = this-&gt;row();
+    if (!row)
+        return nullptr;
+    return downcast&lt;RenderTableSection&gt;(row-&gt;parent());
+}
+
+inline RenderTable* RenderTableCell::table() const
+{
+    RenderTableSection* section = this-&gt;section();
+    if (!section)
+        return nullptr;
+    return downcast&lt;RenderTable&gt;(section-&gt;parent());
+}
+
+inline unsigned RenderTableCell::rowIndex() const
+{
+    // This function shouldn't be called on a detached cell.
+    ASSERT(row());
+    return row()-&gt;rowIndex();
+}
+
+inline Length RenderTableCell::styleOrColLogicalWidth() const
+{
+    Length styleWidth = style().logicalWidth();
+    if (!styleWidth.isAuto())
+        return styleWidth;
+    if (RenderTableCol* firstColumn = table()-&gt;colElement(col()))
+        return logicalWidthFromColumns(firstColumn, styleWidth);
+    return styleWidth;
+}
+
+inline int RenderTableCell::logicalHeightForRowSizing() const
+{
+    // FIXME: This function does too much work, and is very hot during table layout!
+    int adjustedLogicalHeight = pixelSnappedLogicalHeight() - (intrinsicPaddingBefore() + intrinsicPaddingAfter());
+    int styleLogicalHeight = valueForLength(style().logicalHeight(), 0);
+    // In strict mode, box-sizing: content-box do the right thing and actually add in the border and padding.
+    // Call computedCSSPadding* directly to avoid including implicitPadding.
+    if (!document().inQuirksMode() &amp;&amp; style().boxSizing() != BORDER_BOX)
+        styleLogicalHeight += (computedCSSPaddingBefore() + computedCSSPaddingAfter()).floor() + (borderBefore() + borderAfter()).floor();
+    return std::max(styleLogicalHeight, adjustedLogicalHeight);
+}
+
+inline bool RenderTableCell::isBaselineAligned() const
+{
+    EVerticalAlign va = style().verticalAlign();
+    return va == BASELINE || va == TEXT_BOTTOM || va == TEXT_TOP || va == SUPER || va == SUB || va == LENGTH;
+}
+
+inline const BorderValue&amp; RenderTableCell::borderAdjoiningTableStart() const
+{
+    ASSERT(isFirstOrLastCellInRow());
+    if (section()-&gt;hasSameDirectionAs(table()))
+        return style().borderStart();
+
+    return style().borderEnd();
+}
+
+inline const BorderValue&amp; RenderTableCell::borderAdjoiningTableEnd() const
+{
+    ASSERT(isFirstOrLastCellInRow());
+    if (section()-&gt;hasSameDirectionAs(table()))
+        return style().borderEnd();
+
+    return style().borderStart();
+}
+
+inline const BorderValue&amp; RenderTableCell::borderAdjoiningCellBefore(const RenderTableCell* cell)
+{
+    ASSERT_UNUSED(cell, table()-&gt;cellAfter(cell) == this);
+    // FIXME: https://webkit.org/b/79272 - Add support for mixed directionality at the cell level.
+    return style().borderStart();
+}
+
+inline const BorderValue&amp; RenderTableCell::borderAdjoiningCellAfter(const RenderTableCell* cell)
+{
+    ASSERT_UNUSED(cell, table()-&gt;cellBefore(cell) == this);
+    // FIXME: https://webkit.org/b/79272 - Add support for mixed directionality at the cell level.
+    return style().borderEnd();
+}
+
</ins><span class="cx"> inline RenderTableCell* RenderTableRow::firstCell() const
</span><span class="cx"> {
</span><span class="cx">     return downcast&lt;RenderTableCell&gt;(RenderBox::firstChild());
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableColcpp"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCol.cpp (182700 => 182701)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCol.cpp        2015-04-13 10:27:52 UTC (rev 182700)
+++ releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCol.cpp        2015-04-13 10:29:23 UTC (rev 182701)
</span><span class="lines">@@ -39,7 +39,6 @@
</span><span class="cx"> 
</span><span class="cx"> RenderTableCol::RenderTableCol(Element&amp; element, Ref&lt;RenderStyle&gt;&amp;&amp; style)
</span><span class="cx">     : RenderBox(element, WTF::move(style), 0)
</span><del>-    , m_span(1)
</del><span class="cx"> {
</span><span class="cx">     // init RenderObject attributes
</span><span class="cx">     setInline(true); // our object is not Inline
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableColh"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCol.h (182700 => 182701)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCol.h        2015-04-13 10:27:52 UTC (rev 182700)
+++ releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableCol.h        2015-04-13 10:29:23 UTC (rev 182701)
</span><span class="lines">@@ -48,21 +48,9 @@
</span><span class="cx">     bool isTableColumnGroup() const { return style().display() == TABLE_COLUMN_GROUP; }
</span><span class="cx"> 
</span><span class="cx">     RenderTableCol* enclosingColumnGroup() const;
</span><del>-    RenderTableCol* enclosingColumnGroupIfAdjacentBefore() const
-    {
-        if (previousSibling())
-            return 0;
-        return enclosingColumnGroup();
-    }
</del><ins>+    RenderTableCol* enclosingColumnGroupIfAdjacentBefore() const;
+    RenderTableCol* enclosingColumnGroupIfAdjacentAfter() const;
</ins><span class="cx"> 
</span><del>-    RenderTableCol* enclosingColumnGroupIfAdjacentAfter() const
-    {
-        if (nextSibling())
-            return 0;
-        return enclosingColumnGroup();
-    }
-
-
</del><span class="cx">     // Returns the next column or column-group.
</span><span class="cx">     RenderTableCol* nextColumn() const;
</span><span class="cx"> 
</span><span class="lines">@@ -97,9 +85,23 @@
</span><span class="cx"> 
</span><span class="cx">     RenderTable* table() const;
</span><span class="cx"> 
</span><del>-    unsigned m_span;
</del><ins>+    unsigned m_span { 1 };
</ins><span class="cx"> };
</span><span class="cx"> 
</span><ins>+inline RenderTableCol* RenderTableCol::enclosingColumnGroupIfAdjacentBefore() const
+{
+    if (previousSibling())
+        return nullptr;
+    return enclosingColumnGroup();
+}
+
+inline RenderTableCol* RenderTableCol::enclosingColumnGroupIfAdjacentAfter() const
+{
+    if (nextSibling())
+        return nullptr;
+    return enclosingColumnGroup();
+}
+
</ins><span class="cx"> } // namespace WebCore
</span><span class="cx"> 
</span><span class="cx"> SPECIALIZE_TYPE_TRAITS_RENDER_OBJECT(RenderTableCol, isRenderTableCol())
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableRowh"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableRow.h (182700 => 182701)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableRow.h        2015-04-13 10:27:52 UTC (rev 182700)
+++ releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableRow.h        2015-04-13 10:29:23 UTC (rev 182701)
</span><span class="lines">@@ -48,44 +48,14 @@
</span><span class="cx">     void paintOutlineForRowIfNeeded(PaintInfo&amp;, const LayoutPoint&amp;);
</span><span class="cx"> 
</span><span class="cx">     static RenderTableRow* createAnonymousWithParentRenderer(const RenderObject*);
</span><del>-    virtual RenderBox* createAnonymousBoxWithSameTypeAs(const RenderObject* parent) const override
-    {
-        return createAnonymousWithParentRenderer(parent);
-    }
</del><ins>+    virtual RenderBox* createAnonymousBoxWithSameTypeAs(const RenderObject* parent) const override { return createAnonymousWithParentRenderer(parent); }
</ins><span class="cx"> 
</span><del>-    void setRowIndex(unsigned rowIndex)
-    {
-        if (UNLIKELY(rowIndex &gt; maxRowIndex))
-            CRASH();
-
-        m_rowIndex = rowIndex;
-    }
-
</del><ins>+    void setRowIndex(unsigned);
</ins><span class="cx">     bool rowIndexWasSet() const { return m_rowIndex != unsetRowIndex; }
</span><del>-    unsigned rowIndex() const
-    {
-        ASSERT(rowIndexWasSet());
-        return m_rowIndex;
-    }
</del><ins>+    unsigned rowIndex() const;
</ins><span class="cx"> 
</span><del>-    const BorderValue&amp; borderAdjoiningTableStart() const
-    {
-        RenderTableSection* section = this-&gt;section();
-        if (section &amp;&amp; section-&gt;hasSameDirectionAs(table()))
-            return style().borderStart();
-
-        return style().borderEnd();
-    }
-
-    const BorderValue&amp; borderAdjoiningTableEnd() const
-    {
-        RenderTableSection* section = this-&gt;section();
-        if (section &amp;&amp; section-&gt;hasSameDirectionAs(table()))
-            return style().borderEnd();
-
-        return style().borderStart();
-    }
-
</del><ins>+    const BorderValue&amp; borderAdjoiningTableStart() const;
+    const BorderValue&amp; borderAdjoiningTableEnd() const;
</ins><span class="cx">     const BorderValue&amp; borderAdjoiningStartCell(const RenderTableCell*) const;
</span><span class="cx">     const BorderValue&amp; borderAdjoiningEndCell(const RenderTableCell*) const;
</span><span class="cx"> 
</span><span class="lines">@@ -122,22 +92,41 @@
</span><span class="cx">     unsigned m_rowIndex : 31;
</span><span class="cx"> };
</span><span class="cx"> 
</span><del>-inline RenderTable* RenderTableRow::table() const
</del><ins>+inline void RenderTableRow::setRowIndex(unsigned rowIndex)
</ins><span class="cx"> {
</span><ins>+    if (UNLIKELY(rowIndex &gt; maxRowIndex))
+        CRASH();
+    m_rowIndex = rowIndex;
+}
+
+inline unsigned RenderTableRow::rowIndex() const
+{
+    ASSERT(rowIndexWasSet());
+    return m_rowIndex;
+}
+
+inline const BorderValue&amp; RenderTableRow::borderAdjoiningTableStart() const
+{
</ins><span class="cx">     RenderTableSection* section = this-&gt;section();
</span><del>-    if (!section)
-        return nullptr;
-    return downcast&lt;RenderTable&gt;(section-&gt;parent());
</del><ins>+    if (section &amp;&amp; section-&gt;hasSameDirectionAs(table()))
+        return style().borderStart();
+    return style().borderEnd();
</ins><span class="cx"> }
</span><span class="cx"> 
</span><del>-inline RenderTableRow* RenderTableSection::firstRow() const
</del><ins>+inline const BorderValue&amp; RenderTableRow::borderAdjoiningTableEnd() const
</ins><span class="cx"> {
</span><del>-    return downcast&lt;RenderTableRow&gt;(RenderBox::firstChild());
</del><ins>+    RenderTableSection* section = this-&gt;section();
+    if (section &amp;&amp; section-&gt;hasSameDirectionAs(table()))
+        return style().borderEnd();
+    return style().borderStart();
</ins><span class="cx"> }
</span><span class="cx"> 
</span><del>-inline RenderTableRow* RenderTableSection::lastRow() const
</del><ins>+inline RenderTable* RenderTableRow::table() const
</ins><span class="cx"> {
</span><del>-    return downcast&lt;RenderTableRow&gt;(RenderBox::lastChild());
</del><ins>+    RenderTableSection* section = this-&gt;section();
+    if (!section)
+        return nullptr;
+    return downcast&lt;RenderTable&gt;(section-&gt;parent());
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> inline RenderTableRow* RenderTableRow::nextRow() const
</span><span class="lines">@@ -150,6 +139,16 @@
</span><span class="cx">     return downcast&lt;RenderTableRow&gt;(RenderBox::previousSibling());
</span><span class="cx"> }
</span><span class="cx"> 
</span><ins>+inline RenderTableRow* RenderTableSection::firstRow() const
+{
+    return downcast&lt;RenderTableRow&gt;(RenderBox::firstChild());
+}
+
+inline RenderTableRow* RenderTableSection::lastRow() const
+{
+    return downcast&lt;RenderTableRow&gt;(RenderBox::lastChild());
+}
+
</ins><span class="cx"> } // namespace WebCore
</span><span class="cx"> 
</span><span class="cx"> SPECIALIZE_TYPE_TRAITS_RENDER_OBJECT(RenderTableRow, isTableRow())
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableSectioncpp"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableSection.cpp (182700 => 182701)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableSection.cpp        2015-04-13 10:27:52 UTC (rev 182700)
+++ releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableSection.cpp        2015-04-13 10:29:23 UTC (rev 182701)
</span><span class="lines">@@ -84,28 +84,12 @@
</span><span class="cx"> 
</span><span class="cx"> RenderTableSection::RenderTableSection(Element&amp; element, Ref&lt;RenderStyle&gt;&amp;&amp; style)
</span><span class="cx">     : RenderBox(element, WTF::move(style), 0)
</span><del>-    , m_cCol(0)
-    , m_cRow(0)
-    , m_outerBorderStart(0)
-    , m_outerBorderEnd(0)
-    , m_outerBorderBefore(0)
-    , m_outerBorderAfter(0)
-    , m_needsCellRecalc(false)
-    , m_hasMultipleCellLevels(false)
</del><span class="cx"> {
</span><span class="cx">     setInline(false);
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> RenderTableSection::RenderTableSection(Document&amp; document, Ref&lt;RenderStyle&gt;&amp;&amp; style)
</span><span class="cx">     : RenderBox(document, WTF::move(style), 0)
</span><del>-    , m_cCol(0)
-    , m_cRow(0)
-    , m_outerBorderStart(0)
-    , m_outerBorderEnd(0)
-    , m_outerBorderBefore(0)
-    , m_outerBorderAfter(0)
-    , m_needsCellRecalc(false)
-    , m_hasMultipleCellLevels(false)
</del><span class="cx"> {
</span><span class="cx">     setInline(false);
</span><span class="cx"> }
</span><span class="lines">@@ -1044,11 +1028,11 @@
</span><span class="cx">     CellSpan coveredRows = spannedRows(damageRect, IncludeAllIntersectingCells);
</span><span class="cx"> 
</span><span class="cx">     // To repaint the border we might need to repaint first or last row even if they are not spanned themselves.
</span><del>-    if (coveredRows.start() &gt;= m_rowPos.size() - 1 &amp;&amp; m_rowPos[m_rowPos.size() - 1] + table()-&gt;outerBorderAfter() &gt;= damageRect.y())
-        --coveredRows.start();
</del><ins>+    if (coveredRows.start &gt;= m_rowPos.size() - 1 &amp;&amp; m_rowPos[m_rowPos.size() - 1] + table()-&gt;outerBorderAfter() &gt;= damageRect.y())
+        --coveredRows.start;
</ins><span class="cx"> 
</span><del>-    if (!coveredRows.end() &amp;&amp; m_rowPos[0] - table()-&gt;outerBorderBefore() &lt;= damageRect.maxY())
-        ++coveredRows.end();
</del><ins>+    if (!coveredRows.end &amp;&amp; m_rowPos[0] - table()-&gt;outerBorderBefore() &lt;= damageRect.maxY())
+        ++coveredRows.end;
</ins><span class="cx"> 
</span><span class="cx">     return coveredRows;
</span><span class="cx"> }
</span><span class="lines">@@ -1062,11 +1046,11 @@
</span><span class="cx"> 
</span><span class="cx">     const Vector&lt;int&gt;&amp; columnPos = table()-&gt;columnPositions();
</span><span class="cx">     // To repaint the border we might need to repaint first or last column even if they are not spanned themselves.
</span><del>-    if (coveredColumns.start() &gt;= columnPos.size() - 1 &amp;&amp; columnPos[columnPos.size() - 1] + table()-&gt;outerBorderEnd() &gt;= damageRect.x())
-        --coveredColumns.start();
</del><ins>+    if (coveredColumns.start &gt;= columnPos.size() - 1 &amp;&amp; columnPos[columnPos.size() - 1] + table()-&gt;outerBorderEnd() &gt;= damageRect.x())
+        --coveredColumns.start;
</ins><span class="cx"> 
</span><del>-    if (!coveredColumns.end() &amp;&amp; columnPos[0] - table()-&gt;outerBorderStart() &lt;= damageRect.maxX())
-        ++coveredColumns.end();
</del><ins>+    if (!coveredColumns.end &amp;&amp; columnPos[0] - table()-&gt;outerBorderStart() &lt;= damageRect.maxX())
+        ++coveredColumns.end;
</ins><span class="cx"> 
</span><span class="cx">     return coveredColumns;
</span><span class="cx"> }
</span><span class="lines">@@ -1253,17 +1237,17 @@
</span><span class="cx">     CellSpan dirtiedRows = this-&gt;dirtiedRows(tableAlignedRect);
</span><span class="cx">     CellSpan dirtiedColumns = this-&gt;dirtiedColumns(tableAlignedRect);
</span><span class="cx"> 
</span><del>-    if (dirtiedColumns.start() &lt; dirtiedColumns.end()) {
</del><ins>+    if (dirtiedColumns.start &lt; dirtiedColumns.end) {
</ins><span class="cx">         if (!m_hasMultipleCellLevels &amp;&amp; !m_overflowingCells.size()) {
</span><span class="cx">             if (paintInfo.phase == PaintPhaseCollapsedTableBorders) {
</span><span class="cx">                 // Collapsed borders are painted from the bottom right to the top left so that precedence
</span><span class="cx">                 // due to cell position is respected. We need to paint one row beyond the topmost dirtied
</span><span class="cx">                 // row to calculate its collapsed border value.
</span><del>-                unsigned startRow = dirtiedRows.start() ? dirtiedRows.start() - 1 : 0;
-                for (unsigned r = dirtiedRows.end(); r &gt; startRow; r--) {
</del><ins>+                unsigned startRow = dirtiedRows.start ? dirtiedRows.start - 1 : 0;
+                for (unsigned r = dirtiedRows.end; r &gt; startRow; r--) {
</ins><span class="cx">                     unsigned row = r - 1;
</span><span class="cx">                     bool shouldPaintRowGroupBorder = false;
</span><del>-                    for (unsigned c = dirtiedColumns.end(); c &gt; dirtiedColumns.start(); c--) {
</del><ins>+                    for (unsigned c = dirtiedColumns.end; c &gt; dirtiedColumns.start; c--) {
</ins><span class="cx">                         unsigned col = c - 1;
</span><span class="cx">                         CellStruct&amp; current = cellAt(row, col);
</span><span class="cx">                         RenderTableCell* cell = current.primaryCell();
</span><span class="lines">@@ -1275,7 +1259,7 @@
</span><span class="cx">                             shouldPaintRowGroupBorder = true;
</span><span class="cx">                             continue;
</span><span class="cx">                         }
</span><del>-                        if ((row &gt; dirtiedRows.start() &amp;&amp; primaryCellAt(row - 1, col) == cell) || (col &gt; dirtiedColumns.start() &amp;&amp; primaryCellAt(row, col - 1) == cell))
</del><ins>+                        if ((row &gt; dirtiedRows.start &amp;&amp; primaryCellAt(row - 1, col) == cell) || (col &gt; dirtiedColumns.start &amp;&amp; primaryCellAt(row, col - 1) == cell))
</ins><span class="cx">                             continue;
</span><span class="cx">                         
</span><span class="cx">                         // If we had a run of null cells paint their corresponding section of the row group's border if necessary. Note that
</span><span class="lines">@@ -1294,14 +1278,14 @@
</span><span class="cx">                 }
</span><span class="cx">             } else {
</span><span class="cx">                 // Draw the dirty cells in the order that they appear.
</span><del>-                for (unsigned r = dirtiedRows.start(); r &lt; dirtiedRows.end(); r++) {
</del><ins>+                for (unsigned r = dirtiedRows.start; r &lt; dirtiedRows.end; r++) {
</ins><span class="cx">                     RenderTableRow* row = m_grid[r].rowRenderer;
</span><span class="cx">                     if (row &amp;&amp; !row-&gt;hasSelfPaintingLayer())
</span><span class="cx">                         row-&gt;paintOutlineForRowIfNeeded(paintInfo, paintOffset);
</span><del>-                    for (unsigned c = dirtiedColumns.start(); c &lt; dirtiedColumns.end(); c++) {
</del><ins>+                    for (unsigned c = dirtiedColumns.start; c &lt; dirtiedColumns.end; c++) {
</ins><span class="cx">                         CellStruct&amp; current = cellAt(r, c);
</span><span class="cx">                         RenderTableCell* cell = current.primaryCell();
</span><del>-                        if (!cell || (r &gt; dirtiedRows.start() &amp;&amp; primaryCellAt(r - 1, c) == cell) || (c &gt; dirtiedColumns.start() &amp;&amp; primaryCellAt(r, c - 1) == cell))
</del><ins>+                        if (!cell || (r &gt; dirtiedRows.start &amp;&amp; primaryCellAt(r - 1, c) == cell) || (c &gt; dirtiedColumns.start &amp;&amp; primaryCellAt(r, c - 1) == cell))
</ins><span class="cx">                             continue;
</span><span class="cx">                         paintCell(cell, paintInfo, paintOffset);
</span><span class="cx">                     }
</span><span class="lines">@@ -1321,11 +1305,11 @@
</span><span class="cx"> 
</span><span class="cx">             HashSet&lt;RenderTableCell*&gt; spanningCells;
</span><span class="cx"> 
</span><del>-            for (unsigned r = dirtiedRows.start(); r &lt; dirtiedRows.end(); r++) {
</del><ins>+            for (unsigned r = dirtiedRows.start; r &lt; dirtiedRows.end; r++) {
</ins><span class="cx">                 RenderTableRow* row = m_grid[r].rowRenderer;
</span><span class="cx">                 if (row &amp;&amp; !row-&gt;hasSelfPaintingLayer())
</span><span class="cx">                     row-&gt;paintOutlineForRowIfNeeded(paintInfo, paintOffset);
</span><del>-                for (unsigned c = dirtiedColumns.start(); c &lt; dirtiedColumns.end(); c++) {
</del><ins>+                for (unsigned c = dirtiedColumns.start; c &lt; dirtiedColumns.end; c++) {
</ins><span class="cx">                     CellStruct&amp; current = cellAt(r, c);
</span><span class="cx">                     if (!current.hasCells())
</span><span class="cx">                         continue;
</span><span class="lines">@@ -1535,8 +1519,8 @@
</span><span class="cx">     CellSpan columnSpan = spannedColumns(tableAlignedRect, DoNotIncludeAllIntersectingCells);
</span><span class="cx"> 
</span><span class="cx">     // Now iterate over the spanned rows and columns.
</span><del>-    for (unsigned hitRow = rowSpan.start(); hitRow &lt; rowSpan.end(); ++hitRow) {
-        for (unsigned hitColumn = columnSpan.start(); hitColumn &lt; columnSpan.end(); ++hitColumn) {
</del><ins>+    for (unsigned hitRow = rowSpan.start; hitRow &lt; rowSpan.end; ++hitRow) {
+        for (unsigned hitColumn = columnSpan.start; hitColumn &lt; columnSpan.end; ++hitColumn) {
</ins><span class="cx">             CellStruct&amp; current = cellAt(hitRow, hitColumn);
</span><span class="cx"> 
</span><span class="cx">             // If the cell is empty, there's nothing to do
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit28SourceWebCorerenderingRenderTableSectionh"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableSection.h (182700 => 182701)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableSection.h        2015-04-13 10:27:52 UTC (rev 182700)
+++ releases/WebKitGTK/webkit-2.8/Source/WebCore/rendering/RenderTableSection.h        2015-04-13 10:29:23 UTC (rev 182701)
</span><span class="lines">@@ -30,6 +30,7 @@
</span><span class="cx"> 
</span><span class="cx"> namespace WebCore {
</span><span class="cx"> 
</span><ins>+class RenderTableCell;
</ins><span class="cx"> class RenderTableRow;
</span><span class="cx"> 
</span><span class="cx"> enum CollapsedBorderSide {
</span><span class="lines">@@ -40,28 +41,18 @@
</span><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> // Helper class for paintObject.
</span><del>-class CellSpan {
</del><ins>+struct CellSpan {
</ins><span class="cx"> public:
</span><span class="cx">     CellSpan(unsigned start, unsigned end)
</span><del>-        : m_start(start)
-        , m_end(end)
</del><ins>+        : start(start)
+        , end(end)
</ins><span class="cx">     {
</span><span class="cx">     }
</span><span class="cx"> 
</span><del>-    unsigned start() const { return m_start; }
-    unsigned end() const { return m_end; }
-
-    unsigned&amp; start() { return m_start; }
-    unsigned&amp; end() { return m_end; }
-
-private:
-    unsigned m_start;
-    unsigned m_end;
</del><ins>+    unsigned start;
+    unsigned end;
</ins><span class="cx"> };
</span><span class="cx"> 
</span><del>-class RenderTableCell;
-class RenderTableRow;
-
</del><span class="cx"> class RenderTableSection final : public RenderBox {
</span><span class="cx"> public:
</span><span class="cx">     RenderTableSection(Element&amp;, Ref&lt;RenderStyle&gt;&amp;&amp;);
</span><span class="lines">@@ -85,88 +76,34 @@
</span><span class="cx"> 
</span><span class="cx">     struct CellStruct {
</span><span class="cx">         Vector&lt;RenderTableCell*, 1&gt; cells; 
</span><del>-        bool inColSpan; // true for columns after the first in a colspan
</del><ins>+        bool inColSpan { false }; // true for columns after the first in a colspan
</ins><span class="cx"> 
</span><del>-        CellStruct()
-            : inColSpan(false)
-        {
-        }
-
-        RenderTableCell* primaryCell()
-        {
-            return hasCells() ? cells[cells.size() - 1] : 0;
-        }
-
-        const RenderTableCell* primaryCell() const
-        {
-            return hasCells() ? cells[cells.size() - 1] : 0;
-        }
-
</del><ins>+        RenderTableCell* primaryCell() { return hasCells() ? cells[cells.size() - 1] : 0; }
+        const RenderTableCell* primaryCell() const { return hasCells() ? cells[cells.size() - 1] : 0; }
</ins><span class="cx">         bool hasCells() const { return cells.size() &gt; 0; }
</span><span class="cx">     };
</span><span class="cx"> 
</span><span class="cx">     typedef Vector&lt;CellStruct&gt; Row;
</span><del>-
</del><span class="cx">     struct RowStruct {
</span><del>-        RowStruct()
-            : rowRenderer(0)
-            , baseline()
-        {
-        }
-
</del><span class="cx">         Row row;
</span><del>-        RenderTableRow* rowRenderer;
</del><ins>+        RenderTableRow* rowRenderer { nullptr };
</ins><span class="cx">         LayoutUnit baseline;
</span><span class="cx">         Length logicalHeight;
</span><span class="cx">     };
</span><span class="cx"> 
</span><del>-    const BorderValue&amp; borderAdjoiningTableStart() const
-    {
-        if (hasSameDirectionAs(table()))
-            return style().borderStart();
-
-        return style().borderEnd();
-    }
-
-    const BorderValue&amp; borderAdjoiningTableEnd() const
-    {
-        if (hasSameDirectionAs(table()))
-            return style().borderEnd();
-
-        return style().borderStart();
-    }
-
</del><ins>+    const BorderValue&amp; borderAdjoiningTableStart() const;
+    const BorderValue&amp; borderAdjoiningTableEnd() const;
</ins><span class="cx">     const BorderValue&amp; borderAdjoiningStartCell(const RenderTableCell*) const;
</span><span class="cx">     const BorderValue&amp; borderAdjoiningEndCell(const RenderTableCell*) const;
</span><span class="cx"> 
</span><span class="cx">     const RenderTableCell* firstRowCellAdjoiningTableStart() const;
</span><span class="cx">     const RenderTableCell* firstRowCellAdjoiningTableEnd() const;
</span><span class="cx"> 
</span><del>-    CellStruct&amp; cellAt(unsigned row,  unsigned col)
-    {
-        recalcCellsIfNeeded();
-        return m_grid[row].row[col];
-    }
</del><ins>+    CellStruct&amp; cellAt(unsigned row,  unsigned col);
+    const CellStruct&amp; cellAt(unsigned row, unsigned col) const;
+    RenderTableCell* primaryCellAt(unsigned row, unsigned col);
+    RenderTableRow* rowRendererAt(unsigned row) const;
</ins><span class="cx"> 
</span><del>-    const CellStruct&amp; cellAt(unsigned row, unsigned col) const
-    {
-        ASSERT(!m_needsCellRecalc);
-        return m_grid[row].row[col];
-    }
-
-    RenderTableCell* primaryCellAt(unsigned row, unsigned col)
-    {
-        recalcCellsIfNeeded();
-        CellStruct&amp; c = m_grid[row].row[col];
-        return c.primaryCell();
-    }
-
-    RenderTableRow* rowRendererAt(unsigned row) const
-    {
-        ASSERT(!m_needsCellRecalc);
-        return m_grid[row].rowRenderer;
-    }
-
</del><span class="cx">     void appendColumn(unsigned pos);
</span><span class="cx">     void splitColumn(unsigned pos, unsigned first);
</span><span class="cx"> 
</span><span class="lines">@@ -181,57 +118,20 @@
</span><span class="cx">     int outerBorderStart() const { return m_outerBorderStart; }
</span><span class="cx">     int outerBorderEnd() const { return m_outerBorderEnd; }
</span><span class="cx"> 
</span><del>-    int outerBorderLeft(const RenderStyle* styleForCellFlow) const
-    {
-    if (styleForCellFlow-&gt;isHorizontalWritingMode())
-        return styleForCellFlow-&gt;isLeftToRightDirection() ? outerBorderStart() : outerBorderEnd();
-    return styleForCellFlow-&gt;isFlippedBlocksWritingMode() ? outerBorderAfter() : outerBorderBefore();
-    }
</del><ins>+    int outerBorderLeft(const RenderStyle* styleForCellFlow) const;
+    int outerBorderRight(const RenderStyle* styleForCellFlow) const;
+    int outerBorderTop(const RenderStyle* styleForCellFlow) const;
+    int outerBorderBottom(const RenderStyle* styleForCellFlow) const;
</ins><span class="cx"> 
</span><del>-    int outerBorderRight(const RenderStyle* styleForCellFlow) const
-    {
-    if (styleForCellFlow-&gt;isHorizontalWritingMode())
-        return styleForCellFlow-&gt;isLeftToRightDirection() ? outerBorderEnd() : outerBorderStart();
-    return styleForCellFlow-&gt;isFlippedBlocksWritingMode() ? outerBorderBefore() : outerBorderAfter();
-    }
-
-    int outerBorderTop(const RenderStyle* styleForCellFlow) const
-    {
-    if (styleForCellFlow-&gt;isHorizontalWritingMode())
-        return styleForCellFlow-&gt;isFlippedBlocksWritingMode() ? outerBorderAfter() : outerBorderBefore();
-    return styleForCellFlow-&gt;isLeftToRightDirection() ? outerBorderStart() : outerBorderEnd();
-    }
-
-    int outerBorderBottom(const RenderStyle* styleForCellFlow) const
-    {
-    if (styleForCellFlow-&gt;isHorizontalWritingMode())
-        return styleForCellFlow-&gt;isFlippedBlocksWritingMode() ? outerBorderBefore() : outerBorderAfter();
-    return styleForCellFlow-&gt;isLeftToRightDirection() ? outerBorderEnd() : outerBorderStart();
-    }
-
-    unsigned numRows() const
-    {
-        ASSERT(!m_needsCellRecalc);
-        return m_grid.size();
-    }
-
</del><ins>+    unsigned numRows() const;
</ins><span class="cx">     unsigned numColumns() const;
</span><span class="cx">     void recalcCells();
</span><del>-    void recalcCellsIfNeeded()
-    {
-        if (m_needsCellRecalc)
-            recalcCells();
-    }
</del><ins>+    void recalcCellsIfNeeded();
</ins><span class="cx"> 
</span><span class="cx">     bool needsCellRecalc() const { return m_needsCellRecalc; }
</span><span class="cx">     void setNeedsCellRecalc();
</span><span class="cx"> 
</span><del>-    LayoutUnit rowBaseline(unsigned row)
-    {
-        recalcCellsIfNeeded();
-        return m_grid[row].baseline;
-    }
-
</del><ins>+    LayoutUnit rowBaseline(unsigned row);
</ins><span class="cx">     void rowLogicalHeightChanged(unsigned rowIndex);
</span><span class="cx"> 
</span><span class="cx">     void removeCachedCollapsedBorders(const RenderTableCell*);
</span><span class="lines">@@ -243,10 +143,7 @@
</span><span class="cx">     int distributeExtraLogicalHeightToRows(int extraLogicalHeight);
</span><span class="cx"> 
</span><span class="cx">     static RenderTableSection* createAnonymousWithParentRenderer(const RenderObject*);
</span><del>-    virtual RenderBox* createAnonymousBoxWithSameTypeAs(const RenderObject* parent) const override
-    {
-        return createAnonymousWithParentRenderer(parent);
-    }
</del><ins>+    virtual RenderBox* createAnonymousBoxWithSameTypeAs(const RenderObject* parent) const override { return createAnonymousWithParentRenderer(parent); }
</ins><span class="cx">     
</span><span class="cx">     virtual void paint(PaintInfo&amp;, const LayoutPoint&amp;) override;
</span><span class="cx"> 
</span><span class="lines">@@ -292,12 +189,7 @@
</span><span class="cx">     bool hasOverflowingCell() const { return m_overflowingCells.size() || m_forceSlowPaintPathWithOverflowingCell; }
</span><span class="cx">     void computeOverflowFromCells(unsigned totalRows, unsigned nEffCols);
</span><span class="cx"> 
</span><del>-    CellSpan fullTableRowSpan() const
-    {
-        ASSERT(!m_needsCellRecalc);
-        return CellSpan(0, m_grid.size());
-    }
-
</del><ins>+    CellSpan fullTableRowSpan() const;
</ins><span class="cx">     CellSpan fullTableColumnSpan() const { return CellSpan(0, table()-&gt;columns().size()); }
</span><span class="cx"> 
</span><span class="cx">     // Flip the rect so it aligns with the coordinates used by the rowPos and columnPos vectors.
</span><span class="lines">@@ -324,29 +216,120 @@
</span><span class="cx">     Vector&lt;int&gt; m_rowPos;
</span><span class="cx"> 
</span><span class="cx">     // the current insertion position
</span><del>-    unsigned m_cCol;
-    unsigned m_cRow;
</del><ins>+    unsigned m_cCol { 0 };
+    unsigned m_cRow  { 0 };
</ins><span class="cx"> 
</span><del>-    int m_outerBorderStart;
-    int m_outerBorderEnd;
-    int m_outerBorderBefore;
-    int m_outerBorderAfter;
</del><ins>+    int m_outerBorderStart  { 0 };
+    int m_outerBorderEnd  { 0 };
+    int m_outerBorderBefore  { 0 };
+    int m_outerBorderAfter  { 0 };
</ins><span class="cx"> 
</span><del>-    bool m_needsCellRecalc;
</del><ins>+    bool m_needsCellRecalc  { false };
</ins><span class="cx"> 
</span><span class="cx">     // This HashSet holds the overflowing cells for faster painting.
</span><span class="cx">     // If we have more than gMaxAllowedOverflowingCellRatio * total cells, it will be empty
</span><span class="cx">     // and m_forceSlowPaintPathWithOverflowingCell will be set to save memory.
</span><span class="cx">     HashSet&lt;RenderTableCell*&gt; m_overflowingCells;
</span><del>-    bool m_forceSlowPaintPathWithOverflowingCell;
</del><ins>+    bool m_forceSlowPaintPathWithOverflowingCell { false };
</ins><span class="cx"> 
</span><del>-    bool m_hasMultipleCellLevels;
</del><ins>+    bool m_hasMultipleCellLevels { false };
</ins><span class="cx"> 
</span><span class="cx">     // This map holds the collapsed border values for cells with collapsed borders.
</span><span class="cx">     // It is held at RenderTableSection level to spare memory consumption by table cells.
</span><span class="cx">     HashMap&lt;std::pair&lt;const RenderTableCell*, int&gt;, CollapsedBorderValue &gt; m_cellsCollapsedBorders;
</span><span class="cx"> };
</span><span class="cx"> 
</span><ins>+inline const BorderValue&amp; RenderTableSection::borderAdjoiningTableStart() const
+{
+    if (hasSameDirectionAs(table()))
+        return style().borderStart();
+    return style().borderEnd();
+}
+
+inline const BorderValue&amp; RenderTableSection::borderAdjoiningTableEnd() const
+{
+    if (hasSameDirectionAs(table()))
+        return style().borderEnd();
+    return style().borderStart();
+}
+
+inline RenderTableSection::CellStruct&amp; RenderTableSection::cellAt(unsigned row,  unsigned col)
+{
+    recalcCellsIfNeeded();
+    return m_grid[row].row[col];
+}
+
+inline const RenderTableSection::CellStruct&amp; RenderTableSection::cellAt(unsigned row, unsigned col) const
+{
+    ASSERT(!m_needsCellRecalc);
+    return m_grid[row].row[col];
+}
+
+inline RenderTableCell* RenderTableSection::primaryCellAt(unsigned row, unsigned col)
+{
+    recalcCellsIfNeeded();
+    CellStruct&amp; c = m_grid[row].row[col];
+    return c.primaryCell();
+}
+
+inline RenderTableRow* RenderTableSection::rowRendererAt(unsigned row) const
+{
+    ASSERT(!m_needsCellRecalc);
+    return m_grid[row].rowRenderer;
+}
+
+inline int RenderTableSection::outerBorderLeft(const RenderStyle* styleForCellFlow) const
+{
+    if (styleForCellFlow-&gt;isHorizontalWritingMode())
+        return styleForCellFlow-&gt;isLeftToRightDirection() ? outerBorderStart() : outerBorderEnd();
+    return styleForCellFlow-&gt;isFlippedBlocksWritingMode() ? outerBorderAfter() : outerBorderBefore();
+}
+
+inline int RenderTableSection::outerBorderRight(const RenderStyle* styleForCellFlow) const
+{
+    if (styleForCellFlow-&gt;isHorizontalWritingMode())
+        return styleForCellFlow-&gt;isLeftToRightDirection() ? outerBorderEnd() : outerBorderStart();
+    return styleForCellFlow-&gt;isFlippedBlocksWritingMode() ? outerBorderBefore() : outerBorderAfter();
+}
+
+inline int RenderTableSection::outerBorderTop(const RenderStyle* styleForCellFlow) const
+{
+    if (styleForCellFlow-&gt;isHorizontalWritingMode())
+        return styleForCellFlow-&gt;isFlippedBlocksWritingMode() ? outerBorderAfter() : outerBorderBefore();
+    return styleForCellFlow-&gt;isLeftToRightDirection() ? outerBorderStart() : outerBorderEnd();
+}
+
+inline int RenderTableSection::outerBorderBottom(const RenderStyle* styleForCellFlow) const
+{
+    if (styleForCellFlow-&gt;isHorizontalWritingMode())
+        return styleForCellFlow-&gt;isFlippedBlocksWritingMode() ? outerBorderBefore() : outerBorderAfter();
+    return styleForCellFlow-&gt;isLeftToRightDirection() ? outerBorderEnd() : outerBorderStart();
+}
+
+inline unsigned RenderTableSection::numRows() const
+{
+    ASSERT(!m_needsCellRecalc);
+    return m_grid.size();
+}
+
+inline void RenderTableSection::recalcCellsIfNeeded()
+{
+    if (m_needsCellRecalc)
+        recalcCells();
+}
+
+inline LayoutUnit RenderTableSection::rowBaseline(unsigned row)
+{
+    recalcCellsIfNeeded();
+    return m_grid[row].baseline;
+}
+
+inline CellSpan RenderTableSection::fullTableRowSpan() const
+{
+    ASSERT(!m_needsCellRecalc);
+    return CellSpan(0, m_grid.size());
+}
+
</ins><span class="cx"> } // namespace WebCore
</span><span class="cx"> 
</span><span class="cx"> SPECIALIZE_TYPE_TRAITS_RENDER_OBJECT(RenderTableSection, isTableSection())
</span></span></pre>
</div>
</div>

</body>
</html>