Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(139)

Side by Side Diff: Source/core/rendering/RenderTableRow.cpp

Issue 264963004: Mark when we may have been invalidated to early out on repaintTreeAfterLayout. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 /** 1 /**
2 * Copyright (C) 1997 Martin Jones (mjones@kde.org) 2 * Copyright (C) 1997 Martin Jones (mjones@kde.org)
3 * (C) 1997 Torben Weis (weis@kde.org) 3 * (C) 1997 Torben Weis (weis@kde.org)
4 * (C) 1998 Waldo Bastian (bastian@kde.org) 4 * (C) 1998 Waldo Bastian (bastian@kde.org)
5 * (C) 1999 Lars Knoll (knoll@kde.org) 5 * (C) 1999 Lars Knoll (knoll@kde.org)
6 * (C) 1999 Antti Koivisto (koivisto@kde.org) 6 * (C) 1999 Antti Koivisto (koivisto@kde.org)
7 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All r ights reserved. 7 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All r ights reserved.
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public 10 * modify it under the terms of the GNU Library General Public
(...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after
152 RenderBox::addChild(cell, beforeChild); 152 RenderBox::addChild(cell, beforeChild);
153 153
154 if (beforeChild || nextSibling()) 154 if (beforeChild || nextSibling())
155 section()->setNeedsCellRecalc(); 155 section()->setNeedsCellRecalc();
156 } 156 }
157 157
158 void RenderTableRow::layout() 158 void RenderTableRow::layout()
159 { 159 {
160 ASSERT(needsLayout()); 160 ASSERT(needsLayout());
161 161
162 setMayNeedInvalidation(true);
163
162 // Table rows do not add translation. 164 // Table rows do not add translation.
163 LayoutStateMaintainer statePusher(*this, LayoutSize()); 165 LayoutStateMaintainer statePusher(*this, LayoutSize());
164 166
165 for (RenderObject* child = firstChild(); child; child = child->nextSibling() ) { 167 for (RenderObject* child = firstChild(); child; child = child->nextSibling() ) {
166 if (child->isTableCell()) { 168 if (child->isTableCell()) {
167 SubtreeLayoutScope layouter(*child); 169 SubtreeLayoutScope layouter(*child);
168 RenderTableCell* cell = toRenderTableCell(child); 170 RenderTableCell* cell = toRenderTableCell(child);
169 if (!cell->needsLayout()) 171 if (!cell->needsLayout())
170 cell->markForPaginationRelayoutIfNeeded(layouter); 172 cell->markForPaginationRelayoutIfNeeded(layouter);
171 if (cell->needsLayout()) { 173 if (cell->needsLayout()) {
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
264 266
265 RenderTableRow* RenderTableRow::createAnonymousWithParentRenderer(const RenderOb ject* parent) 267 RenderTableRow* RenderTableRow::createAnonymousWithParentRenderer(const RenderOb ject* parent)
266 { 268 {
267 RenderTableRow* newRow = RenderTableRow::createAnonymous(&parent->document() ); 269 RenderTableRow* newRow = RenderTableRow::createAnonymous(&parent->document() );
268 RefPtr<RenderStyle> newStyle = RenderStyle::createAnonymousStyleWithDisplay( parent->style(), TABLE_ROW); 270 RefPtr<RenderStyle> newStyle = RenderStyle::createAnonymousStyleWithDisplay( parent->style(), TABLE_ROW);
269 newRow->setStyle(newStyle.release()); 271 newRow->setStyle(newStyle.release());
270 return newRow; 272 return newRow;
271 } 273 }
272 274
273 } // namespace WebCore 275 } // namespace WebCore
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698