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

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

Issue 254573006: Avoid markDirty when removing out-of-flow line boxes. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 8 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
« no previous file with comments | « Source/core/rendering/InlineFlowBox.cpp ('k') | Source/core/rendering/RenderBox.cpp » ('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) 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 691 matching lines...) Expand 10 before | Expand all | Expand 10 after
702 if (r->m_object->isOutOfFlowPositioned()) 702 if (r->m_object->isOutOfFlowPositioned())
703 r->m_box->setLogicalTop(logicalHeight().toFloat()); 703 r->m_box->setLogicalTop(logicalHeight().toFloat());
704 704
705 // Position is used to properly position both replaced elements and 705 // Position is used to properly position both replaced elements and
706 // to update the static normal flow x/y of positioned elements. 706 // to update the static normal flow x/y of positioned elements.
707 if (r->m_object->isText()) 707 if (r->m_object->isText())
708 toRenderText(r->m_object)->positionLineBox(r->m_box); 708 toRenderText(r->m_object)->positionLineBox(r->m_box);
709 else if (r->m_object->isBox()) 709 else if (r->m_object->isBox())
710 toRenderBox(r->m_object)->positionLineBox(r->m_box); 710 toRenderBox(r->m_object)->positionLineBox(r->m_box);
711 } 711 }
712 // Positioned objects and zero-length text nodes destroy their boxes in
713 // position(), which unnecessarily dirties the line.
714 lineBox->markDirty(false);
715 } 712 }
716 713
717 void RenderBlockFlow::appendFloatingObjectToLastLine(FloatingObject* floatingObj ect) 714 void RenderBlockFlow::appendFloatingObjectToLastLine(FloatingObject* floatingObj ect)
718 { 715 {
719 ASSERT(!floatingObject->originatingLine()); 716 ASSERT(!floatingObject->originatingLine());
720 floatingObject->setOriginatingLine(lastRootBox()); 717 floatingObject->setOriginatingLine(lastRootBox());
721 lastRootBox()->appendFloat(floatingObject->renderer()); 718 lastRootBox()->appendFloat(floatingObject->renderer());
722 } 719 }
723 720
724 // FIXME: This should be a BidiStatus constructor or create method. 721 // FIXME: This should be a BidiStatus constructor or create method.
(...skipping 1471 matching lines...) Expand 10 before | Expand all | Expand 10 after
2196 float logicalLeft = logicalLeftOffsetForLine(logicalHeight(), false).toFloat (); 2193 float logicalLeft = logicalLeftOffsetForLine(logicalHeight(), false).toFloat ();
2197 float availableLogicalWidth = logicalRightOffsetForLine(logicalHeight(), fal se) - logicalLeft; 2194 float availableLogicalWidth = logicalRightOffsetForLine(logicalHeight(), fal se) - logicalLeft;
2198 updateLogicalWidthForAlignment(textAlign, 0, 0, logicalLeft, totalLogicalWid th, availableLogicalWidth, 0); 2195 updateLogicalWidthForAlignment(textAlign, 0, 0, logicalLeft, totalLogicalWid th, availableLogicalWidth, 0);
2199 2196
2200 if (!style()->isLeftToRightDirection()) 2197 if (!style()->isLeftToRightDirection())
2201 return logicalWidth() - logicalLeft; 2198 return logicalWidth() - logicalLeft;
2202 return logicalLeft; 2199 return logicalLeft;
2203 } 2200 }
2204 2201
2205 } 2202 }
OLDNEW
« no previous file with comments | « Source/core/rendering/InlineFlowBox.cpp ('k') | Source/core/rendering/RenderBox.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698