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

Unified Diff: Source/WebCore/rendering/RenderBlockLineLayout.cpp

Issue 6948015: Merge 85705 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/742/
Patch Set: Created 9 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/WebCore/rendering/RenderBlock.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/WebCore/rendering/RenderBlockLineLayout.cpp
===================================================================
--- Source/WebCore/rendering/RenderBlockLineLayout.cpp (revision 86001)
+++ Source/WebCore/rendering/RenderBlockLineLayout.cpp (working copy)
@@ -716,12 +716,8 @@
void RenderBlock::appendFloatingObjectToLastLine(FloatingObject* floatingObject)
{
- // Ensure that the float touches the line.
- if (RootInlineBox* previousLine = lastRootBox()->prevRootBox()) {
- if (logicalBottomForFloat(floatingObject) < previousLine->blockLogicalHeight())
- setLogicalHeightForFloat(floatingObject, previousLine->blockLogicalHeight() - logicalTopForFloat(floatingObject));
- }
-
+ ASSERT(!floatingObject->m_originatingLine);
+ floatingObject->m_originatingLine = lastRootBox();
lastRootBox()->appendFloat(floatingObject->renderer());
}
@@ -1041,7 +1037,9 @@
if (Vector<RenderBox*>* cleanLineFloats = line->floatsPtr()) {
Vector<RenderBox*>::iterator end = cleanLineFloats->end();
for (Vector<RenderBox*>::iterator f = cleanLineFloats->begin(); f != end; ++f) {
- insertFloatingObject(*f);
+ FloatingObject* floatingObject = insertFloatingObject(*f);
+ ASSERT(!floatingObject->m_originatingLine);
+ floatingObject->m_originatingLine = line;
setLogicalHeight(logicalTopForChild(*f) - marginBeforeForChild(*f) + delta);
positionNewFloats();
}
@@ -1244,7 +1242,9 @@
if (Vector<RenderBox*>* cleanLineFloats = line->floatsPtr()) {
Vector<RenderBox*>::iterator end = cleanLineFloats->end();
for (Vector<RenderBox*>::iterator f = cleanLineFloats->begin(); f != end; ++f) {
- insertFloatingObject(*f);
+ FloatingObject* floatingObject = insertFloatingObject(*f);
+ ASSERT(!floatingObject->m_originatingLine);
+ floatingObject->m_originatingLine = line;
setLogicalHeight(logicalTopForChild(*f) - marginBeforeForChild(*f));
positionNewFloats();
ASSERT(floats[numCleanFloats].object == *f);
« no previous file with comments | « Source/WebCore/rendering/RenderBlock.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698