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/layout/LayoutBlockFlowLine.cpp

Issue 1308433003: Dirty line boxes correctly when a float gets layout (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 4 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 | « LayoutTests/platform/linux/fast/repaint/line-flow-with-floats-9-expected.txt ('k') | no next file » | 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) 2000 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org)
3 * Copyright (C) 2003, 2004, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ight reserved. 3 * Copyright (C) 2003, 2004, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r ight reserved.
4 * Copyright (C) 2010 Google Inc. All rights reserved. 4 * Copyright (C) 2010 Google Inc. All rights reserved.
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
(...skipping 1531 matching lines...) Expand 10 before | Expand all | Expand 10 after
1542 LayoutBox* box = toLayoutBox(o); 1542 LayoutBox* box = toLayoutBox(o);
1543 1543
1544 updateBlockChildDirtyBitsBeforeLayout(relayoutChildren, *box); 1544 updateBlockChildDirtyBitsBeforeLayout(relayoutChildren, *box);
1545 1545
1546 if (o->isOutOfFlowPositioned()) { 1546 if (o->isOutOfFlowPositioned()) {
1547 o->containingBlock()->insertPositionedObject(box); 1547 o->containingBlock()->insertPositionedObject(box);
1548 } else if (o->isFloating()) { 1548 } else if (o->isFloating()) {
1549 layoutState.floats().append(FloatWithRect(box)); 1549 layoutState.floats().append(FloatWithRect(box));
1550 if (box->needsLayout()) { 1550 if (box->needsLayout()) {
1551 box->layout(); 1551 box->layout();
1552 dirtyLinesFromChangedChild(o); 1552 markLinesDirtyInBlockRange(toLayoutBox(o)->logicalTop(), toLayoutBox(o)->logicalBottom());
rhogan 2015/08/21 13:15:29 Oops, I should use |box| here. I'll address that w
1553 } 1553 }
1554 } else if (isFullLayout || o->needsLayout()) { 1554 } else if (isFullLayout || o->needsLayout()) {
1555 // Replaced element. 1555 // Replaced element.
1556 box->dirtyLineBoxes(isFullLayout); 1556 box->dirtyLineBoxes(isFullLayout);
1557 if (isFullLayout) 1557 if (isFullLayout)
1558 replacedChildren.append(box); 1558 replacedChildren.append(box);
1559 else 1559 else
1560 o->layoutIfNeeded(); 1560 o->layoutIfNeeded();
1561 } 1561 }
1562 } else if (o->isText() || (o->isLayoutInline() && !walker.atEndOfInl ine())) { 1562 } else if (o->isText() || (o->isLayoutInline() && !walker.atEndOfInl ine())) {
(...skipping 450 matching lines...) Expand 10 before | Expand all | Expand 10 after
2013 LayoutUnit logicalLeft = logicalLeftOffsetForLine(logicalHeight(), false); 2013 LayoutUnit logicalLeft = logicalLeftOffsetForLine(logicalHeight(), false);
2014 LayoutUnit availableLogicalWidth = logicalRightOffsetForLine(logicalHeight() , false) - logicalLeft; 2014 LayoutUnit availableLogicalWidth = logicalRightOffsetForLine(logicalHeight() , false) - logicalLeft;
2015 updateLogicalWidthForAlignment(textAlign, 0, 0, logicalLeft, totalLogicalWid th, availableLogicalWidth, 0); 2015 updateLogicalWidthForAlignment(textAlign, 0, 0, logicalLeft, totalLogicalWid th, availableLogicalWidth, 0);
2016 2016
2017 if (!style()->isLeftToRightDirection()) 2017 if (!style()->isLeftToRightDirection())
2018 return logicalWidth() - logicalLeft; 2018 return logicalWidth() - logicalLeft;
2019 return logicalLeft; 2019 return logicalLeft;
2020 } 2020 }
2021 2021
2022 } 2022 }
OLDNEW
« no previous file with comments | « LayoutTests/platform/linux/fast/repaint/line-flow-with-floats-9-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698