| OLD | NEW |
| 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 400 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 411 section->computeOverflowFromCells(); | 411 section->computeOverflowFromCells(); |
| 412 section->updateLayerTransformAfterLayout(); | 412 section->updateLayerTransformAfterLayout(); |
| 413 section->addVisualEffectOverflow(); | 413 section->addVisualEffectOverflow(); |
| 414 } | 414 } |
| 415 } | 415 } |
| 416 | 416 |
| 417 void LayoutTable::layout() | 417 void LayoutTable::layout() |
| 418 { | 418 { |
| 419 ASSERT(needsLayout()); | 419 ASSERT(needsLayout()); |
| 420 LayoutAnalyzer::Scope analyzer(*this); | 420 LayoutAnalyzer::Scope analyzer(*this); |
| 421 SubtreeLayoutScope layouter(*this); |
| 421 | 422 |
| 422 if (simplifiedLayout()) | 423 if (simplifiedLayout(&layouter)) |
| 423 return; | 424 return; |
| 424 | 425 |
| 425 // Note: LayoutTable is handled differently than other LayoutBlocks and the
LayoutScope | 426 // Note: LayoutTable is handled differently than other LayoutBlocks and the
LayoutScope |
| 426 // must be created before the table begins laying out. | 427 // must be created before the table begins laying out. |
| 427 TextAutosizer::LayoutScope textAutosizerLayoutScope(this); | 428 TextAutosizer::LayoutScope textAutosizerLayoutScope(this, &layouter); |
| 428 | 429 |
| 429 recalcSectionsIfNeeded(); | 430 recalcSectionsIfNeeded(); |
| 430 // FIXME: We should do this recalc lazily in borderStart/borderEnd so that w
e don't have to make sure | 431 // FIXME: We should do this recalc lazily in borderStart/borderEnd so that w
e don't have to make sure |
| 431 // to call this before we call borderStart/borderEnd to avoid getting a stal
e value. | 432 // to call this before we call borderStart/borderEnd to avoid getting a stal
e value. |
| 432 recalcBordersInRowDirection(); | 433 recalcBordersInRowDirection(); |
| 433 | 434 |
| 434 SubtreeLayoutScope layouter(*this); | |
| 435 | |
| 436 // If any table section moved vertically, we will just issue paint invalidat
ions for everything from that | 435 // If any table section moved vertically, we will just issue paint invalidat
ions for everything from that |
| 437 // section down (it is quite unlikely that any of the following sections | 436 // section down (it is quite unlikely that any of the following sections |
| 438 // did not shift). | 437 // did not shift). |
| 439 bool sectionMoved = false; | 438 bool sectionMoved = false; |
| 440 { | 439 { |
| 441 LayoutState state(*this, locationOffset()); | 440 LayoutState state(*this, locationOffset()); |
| 442 LayoutUnit oldLogicalWidth = logicalWidth(); | 441 LayoutUnit oldLogicalWidth = logicalWidth(); |
| 443 LayoutUnit oldLogicalHeight = logicalHeight(); | 442 LayoutUnit oldLogicalHeight = logicalHeight(); |
| 444 | 443 |
| 445 setLogicalHeight(LayoutUnit()); | 444 setLogicalHeight(LayoutUnit()); |
| (...skipping 1015 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1461 | 1460 |
| 1462 LayoutUnit LayoutTable::paddingRight() const | 1461 LayoutUnit LayoutTable::paddingRight() const |
| 1463 { | 1462 { |
| 1464 if (collapseBorders()) | 1463 if (collapseBorders()) |
| 1465 return LayoutUnit(); | 1464 return LayoutUnit(); |
| 1466 | 1465 |
| 1467 return LayoutBlock::paddingRight(); | 1466 return LayoutBlock::paddingRight(); |
| 1468 } | 1467 } |
| 1469 | 1468 |
| 1470 } // namespace blink | 1469 } // namespace blink |
| OLD | NEW |