OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
4 * (C) 2007 David Smith (catfish.man@gmail.com) | 4 * (C) 2007 David Smith (catfish.man@gmail.com) |
5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserved. | 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights reserved. |
6 * Copyright (C) Research In Motion Limited 2010. All rights reserved. | 6 * Copyright (C) Research In Motion Limited 2010. All rights reserved. |
7 * | 7 * |
8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
(...skipping 361 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
372 // Note, we don't want to early out here using shouldCheckForInvalidationAft erLayout as | 372 // Note, we don't want to early out here using shouldCheckForInvalidationAft erLayout as |
373 // we have to make sure we go through any positioned objects as they won't b e seen in | 373 // we have to make sure we go through any positioned objects as they won't b e seen in |
374 // the normal tree walk. | 374 // the normal tree walk. |
375 | 375 |
376 if (shouldCheckForPaintInvalidationAfterLayout()) | 376 if (shouldCheckForPaintInvalidationAfterLayout()) |
377 RenderBox::invalidateTreeAfterLayout(invalidationContainer); | 377 RenderBox::invalidateTreeAfterLayout(invalidationContainer); |
378 | 378 |
379 // Take care of positioned objects. This is required as LayoutState keeps a single clip rect. | 379 // Take care of positioned objects. This is required as LayoutState keeps a single clip rect. |
380 if (TrackedRendererListHashSet* positionedObjects = this->positionedObjects( )) { | 380 if (TrackedRendererListHashSet* positionedObjects = this->positionedObjects( )) { |
381 TrackedRendererListHashSet::iterator end = positionedObjects->end(); | 381 TrackedRendererListHashSet::iterator end = positionedObjects->end(); |
382 LayoutStateMaintainer statePusher(*this, isTableRow() ? LayoutSize() : l ocationOffset()); | 382 LayoutState statePusher(*this, isTableRow() ? LayoutSize() : locationOff set()); |
esprehn
2014/06/13 23:25:26
we should really call these state not statePusher
leviw_travelin_and_unemployed
2014/06/13 23:46:16
Sure!
| |
383 for (TrackedRendererListHashSet::iterator it = positionedObjects->begin( ); it != end; ++it) { | 383 for (TrackedRendererListHashSet::iterator it = positionedObjects->begin( ); it != end; ++it) { |
384 RenderBox* box = *it; | 384 RenderBox* box = *it; |
385 | 385 |
386 // One of the renderers we're skipping over here may be the child's repaint container, | 386 // One of the renderers we're skipping over here may be the child's repaint container, |
387 // so we can't pass our own repaint container along. | 387 // so we can't pass our own repaint container along. |
388 const RenderLayerModelObject& repaintContainerForChild = *box->conta inerForPaintInvalidation(); | 388 const RenderLayerModelObject& repaintContainerForChild = *box->conta inerForPaintInvalidation(); |
389 | 389 |
390 // If the positioned renderer is absolutely positioned and it is ins ide | 390 // If the positioned renderer is absolutely positioned and it is ins ide |
391 // a relatively positioend inline element, we need to account for | 391 // a relatively positioend inline element, we need to account for |
392 // the inline elements position in LayoutState. | 392 // the inline elements position in LayoutState. |
(...skipping 1175 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
1568 // Check if we need to do a full layout. | 1568 // Check if we need to do a full layout. |
1569 if (normalChildNeedsLayout() || selfNeedsLayout()) | 1569 if (normalChildNeedsLayout() || selfNeedsLayout()) |
1570 return false; | 1570 return false; |
1571 | 1571 |
1572 // Check that we actually need to do a simplified layout. | 1572 // Check that we actually need to do a simplified layout. |
1573 if (!posChildNeedsLayout() && !(needsSimplifiedNormalFlowLayout() || needsPo sitionedMovementLayout())) | 1573 if (!posChildNeedsLayout() && !(needsSimplifiedNormalFlowLayout() || needsPo sitionedMovementLayout())) |
1574 return false; | 1574 return false; |
1575 | 1575 |
1576 | 1576 |
1577 { | 1577 { |
1578 // LayoutStateMaintainer needs this deliberate scope to pop before repai nt | 1578 // LayoutState needs this deliberate scope to pop before repaint |
1579 LayoutStateMaintainer statePusher(*this, locationOffset()); | 1579 LayoutState statePusher(*this, locationOffset()); |
esprehn
2014/06/13 23:25:26
LayoutState state(...)
| |
1580 | 1580 |
1581 if (needsPositionedMovementLayout() && !tryLayoutDoingPositionedMovement Only()) | 1581 if (needsPositionedMovementLayout() && !tryLayoutDoingPositionedMovement Only()) |
1582 return false; | 1582 return false; |
1583 | 1583 |
1584 FastTextAutosizer::LayoutScope fastTextAutosizerLayoutScope(this); | 1584 FastTextAutosizer::LayoutScope fastTextAutosizerLayoutScope(this); |
1585 | 1585 |
1586 // Lay out positioned descendants or objects that just need to recompute overflow. | 1586 // Lay out positioned descendants or objects that just need to recompute overflow. |
1587 if (needsSimplifiedNormalFlowLayout()) | 1587 if (needsSimplifiedNormalFlowLayout()) |
1588 simplifiedNormalFlowLayout(); | 1588 simplifiedNormalFlowLayout(); |
1589 | 1589 |
(...skipping 3457 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
5047 void RenderBlock::showLineTreeAndMark(const InlineBox* markedBox1, const char* m arkedLabel1, const InlineBox* markedBox2, const char* markedLabel2, const Render Object* obj) const | 5047 void RenderBlock::showLineTreeAndMark(const InlineBox* markedBox1, const char* m arkedLabel1, const InlineBox* markedBox2, const char* markedLabel2, const Render Object* obj) const |
5048 { | 5048 { |
5049 showRenderObject(); | 5049 showRenderObject(); |
5050 for (const RootInlineBox* root = firstRootBox(); root; root = root->nextRoot Box()) | 5050 for (const RootInlineBox* root = firstRootBox(); root; root = root->nextRoot Box()) |
5051 root->showLineTreeAndMark(markedBox1, markedLabel1, markedBox2, markedLa bel2, obj, 1); | 5051 root->showLineTreeAndMark(markedBox1, markedLabel1, markedBox2, markedLa bel2, obj, 1); |
5052 } | 5052 } |
5053 | 5053 |
5054 #endif | 5054 #endif |
5055 | 5055 |
5056 } // namespace WebCore | 5056 } // namespace WebCore |
OLD | NEW |