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

Side by Side Diff: Source/WebCore/rendering/RenderBlock.cpp

Issue 6480006: Merge 77565 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/648/
Patch Set: Created 9 years, 10 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 | « LayoutTests/fast/overflow/overflow-height-float-not-removed-crash-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) 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 Apple Inc. All r ights reserved. 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All r ights 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 3065 matching lines...) Expand 10 before | Expand all | Expand 10 after
3076 DeprecatedPtrListIterator<FloatingObject> it(*m_floatingObjects); 3076 DeprecatedPtrListIterator<FloatingObject> it(*m_floatingObjects);
3077 while (it.current()) { 3077 while (it.current()) {
3078 if (it.current()->m_renderer == o) { 3078 if (it.current()->m_renderer == o) {
3079 if (childrenInline()) { 3079 if (childrenInline()) {
3080 int logicalTop = logicalTopForFloat(it.current()); 3080 int logicalTop = logicalTopForFloat(it.current());
3081 int logicalBottom = logicalBottomForFloat(it.current()); 3081 int logicalBottom = logicalBottomForFloat(it.current());
3082 3082
3083 // Special-case zero- and less-than-zero-height floats: thos e don't touch 3083 // Special-case zero- and less-than-zero-height floats: thos e don't touch
3084 // the line that they're on, but it still needs to be dirtie d. This is 3084 // the line that they're on, but it still needs to be dirtie d. This is
3085 // accomplished by pretending they have a height of 1. 3085 // accomplished by pretending they have a height of 1.
3086 logicalBottom = max(logicalBottom, logicalTop + 1); 3086 logicalBottom = max(logicalBottom, max(logicalTop + 1, logic alTop));
3087 markLinesDirtyInBlockRange(0, logicalBottom); 3087 markLinesDirtyInBlockRange(0, logicalBottom);
3088 } 3088 }
3089 m_floatingObjects->removeRef(it.current()); 3089 m_floatingObjects->removeRef(it.current());
3090 } 3090 }
3091 ++it; 3091 ++it;
3092 } 3092 }
3093 } 3093 }
3094 } 3094 }
3095 3095
3096 void RenderBlock::removeFloatingObjectsBelow(FloatingObject* lastFloat, int y) 3096 void RenderBlock::removeFloatingObjectsBelow(FloatingObject* lastFloat, int y)
(...skipping 341 matching lines...) Expand 10 before | Expand all | Expand 10 after
3438 return lowestFloatBottom; 3438 return lowestFloatBottom;
3439 } 3439 }
3440 3440
3441 void RenderBlock::markLinesDirtyInBlockRange(int logicalTop, int logicalBottom, RootInlineBox* highest) 3441 void RenderBlock::markLinesDirtyInBlockRange(int logicalTop, int logicalBottom, RootInlineBox* highest)
3442 { 3442 {
3443 if (logicalTop >= logicalBottom) 3443 if (logicalTop >= logicalBottom)
3444 return; 3444 return;
3445 3445
3446 RootInlineBox* lowestDirtyLine = lastRootBox(); 3446 RootInlineBox* lowestDirtyLine = lastRootBox();
3447 RootInlineBox* afterLowest = lowestDirtyLine; 3447 RootInlineBox* afterLowest = lowestDirtyLine;
3448 while (lowestDirtyLine && lowestDirtyLine->blockLogicalHeight() >= logicalBo ttom) { 3448 while (lowestDirtyLine && lowestDirtyLine->blockLogicalHeight() >= logicalBo ttom && logicalBottom < numeric_limits<int>::max()) {
3449 afterLowest = lowestDirtyLine; 3449 afterLowest = lowestDirtyLine;
3450 lowestDirtyLine = lowestDirtyLine->prevRootBox(); 3450 lowestDirtyLine = lowestDirtyLine->prevRootBox();
3451 } 3451 }
3452 3452
3453 while (afterLowest && afterLowest != highest && afterLowest->blockLogicalHei ght() >= logicalTop) { 3453 while (afterLowest && afterLowest != highest && afterLowest->blockLogicalHei ght() >= logicalTop) {
3454 afterLowest->markDirty(); 3454 afterLowest->markDirty();
3455 afterLowest = afterLowest->prevRootBox(); 3455 afterLowest = afterLowest->prevRootBox();
3456 } 3456 }
3457 } 3457 }
3458 3458
(...skipping 2618 matching lines...) Expand 10 before | Expand all | Expand 10 after
6077 else if (isAnonymous()) 6077 else if (isAnonymous())
6078 return "RenderBlock (generated)"; 6078 return "RenderBlock (generated)";
6079 if (isRelPositioned()) 6079 if (isRelPositioned())
6080 return "RenderBlock (relative positioned)"; 6080 return "RenderBlock (relative positioned)";
6081 if (isRunIn()) 6081 if (isRunIn())
6082 return "RenderBlock (run-in)"; 6082 return "RenderBlock (run-in)";
6083 return "RenderBlock"; 6083 return "RenderBlock";
6084 } 6084 }
6085 6085
6086 } // namespace WebCore 6086 } // namespace WebCore
OLDNEW
« no previous file with comments | « LayoutTests/fast/overflow/overflow-height-float-not-removed-crash-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698