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

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

Issue 332543002: Rename Repaint to Paint Invalidation Part 4 (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years, 6 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
« no previous file with comments | « Source/core/rendering/RenderTable.h ('k') | Source/core/rendering/RenderTableCell.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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, 2013 Apple Inc. All rights reserved. 7 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2013 Apple Inc. All rights reserved.
8 * Copyright (C) 2006 Alexey Proskuryakov (ap@nypop.com) 8 * Copyright (C) 2006 Alexey Proskuryakov (ap@nypop.com)
9 * 9 *
10 * This library is free software; you can redistribute it and/or 10 * This library is free software; you can redistribute it and/or
(...skipping 363 matching lines...) Expand 10 before | Expand all | Expand 10 after
374 caption->layoutIfNeeded(); 374 caption->layoutIfNeeded();
375 } 375 }
376 // Apply the margins to the location now that they are definitely available from layout 376 // Apply the margins to the location now that they are definitely available from layout
377 LayoutUnit captionLogicalTop = collapsedMarginBeforeForChild(caption) + logi calHeight(); 377 LayoutUnit captionLogicalTop = collapsedMarginBeforeForChild(caption) + logi calHeight();
378 if (view()->layoutState()->isPaginated()) { 378 if (view()->layoutState()->isPaginated()) {
379 captionLogicalTop += caption->paginationStrut(); 379 captionLogicalTop += caption->paginationStrut();
380 caption->setPaginationStrut(0); 380 caption->setPaginationStrut(0);
381 } 381 }
382 caption->setLogicalLocation(LayoutPoint(caption->marginStart(), captionLogic alTop)); 382 caption->setLogicalLocation(LayoutPoint(caption->marginStart(), captionLogic alTop));
383 383
384 if (!selfNeedsLayout() && caption->checkForRepaintDuringLayout()) 384 if (!selfNeedsLayout() && caption->checkForPaintInvalidationDuringLayout())
385 caption->repaintDuringLayoutIfMoved(captionRect); 385 caption->repaintDuringLayoutIfMoved(captionRect);
386 386
387 setLogicalHeight(logicalHeight() + caption->logicalHeight() + collapsedMargi nBeforeForChild(caption) + collapsedMarginAfterForChild(caption)); 387 setLogicalHeight(logicalHeight() + caption->logicalHeight() + collapsedMargi nBeforeForChild(caption) + collapsedMarginAfterForChild(caption));
388 } 388 }
389 389
390 void RenderTable::distributeExtraLogicalHeight(int extraLogicalHeight) 390 void RenderTable::distributeExtraLogicalHeight(int extraLogicalHeight)
391 { 391 {
392 if (extraLogicalHeight <= 0) 392 if (extraLogicalHeight <= 0)
393 return; 393 return;
394 394
(...skipping 23 matching lines...) Expand all
418 418
419 // Note: RenderTable is handled differently than other RenderBlocks and the LayoutScope 419 // Note: RenderTable is handled differently than other RenderBlocks and the LayoutScope
420 // must be created before the table begins laying out. 420 // must be created before the table begins laying out.
421 FastTextAutosizer::LayoutScope fastTextAutosizerLayoutScope(this); 421 FastTextAutosizer::LayoutScope fastTextAutosizerLayoutScope(this);
422 422
423 recalcSectionsIfNeeded(); 423 recalcSectionsIfNeeded();
424 // FIXME: We should do this recalc lazily in borderStart/borderEnd so that w e don't have to make sure 424 // FIXME: We should do this recalc lazily in borderStart/borderEnd so that w e don't have to make sure
425 // to call this before we call borderStart/borderEnd to avoid getting a stal e value. 425 // to call this before we call borderStart/borderEnd to avoid getting a stal e value.
426 recalcBordersInRowDirection(); 426 recalcBordersInRowDirection();
427 427
428 LayoutRepainter repainter(*this, checkForRepaintDuringLayout()); 428 LayoutRepainter repainter(*this, checkForPaintInvalidationDuringLayout());
429 SubtreeLayoutScope layouter(*this); 429 SubtreeLayoutScope layouter(*this);
430 430
431 431
432 // If any table section moved vertically, we will just repaint everything fr om that 432 // If any table section moved vertically, we will just repaint everything fr om that
433 // section down (it is quite unlikely that any of the following sections 433 // section down (it is quite unlikely that any of the following sections
434 // did not shift). 434 // did not shift).
435 bool sectionMoved = false; 435 bool sectionMoved = false;
436 LayoutUnit movedSectionLogicalTop = 0; 436 LayoutUnit movedSectionLogicalTop = 0;
437 { 437 {
438 LayoutStateMaintainer statePusher(*this, locationOffset()); 438 LayoutStateMaintainer statePusher(*this, locationOffset());
(...skipping 1014 matching lines...) Expand 10 before | Expand all | Expand 10 after
1453 const BorderValue& RenderTable::tableEndBorderAdjoiningCell(const RenderTableCel l* cell) const 1453 const BorderValue& RenderTable::tableEndBorderAdjoiningCell(const RenderTableCel l* cell) const
1454 { 1454 {
1455 ASSERT(cell->isFirstOrLastCellInRow()); 1455 ASSERT(cell->isFirstOrLastCellInRow());
1456 if (hasSameDirectionAs(cell->row())) 1456 if (hasSameDirectionAs(cell->row()))
1457 return style()->borderEnd(); 1457 return style()->borderEnd();
1458 1458
1459 return style()->borderStart(); 1459 return style()->borderStart();
1460 } 1460 }
1461 1461
1462 } 1462 }
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderTable.h ('k') | Source/core/rendering/RenderTableCell.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698