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

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

Issue 7634029: Merge 92798 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/835/
Patch Set: Created 9 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
« no previous file with comments | « LayoutTests/fast/block/float/float-originating-line-deleted-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 3186 matching lines...) Expand 10 before | Expand all | Expand 10 after
3197 // Fix for https://bugs.webkit.org/show_bug.cgi?id=54995. 3197 // Fix for https://bugs.webkit.org/show_bug.cgi?id=54995.
3198 if (logicalBottom < 0 || logicalBottom < logicalTop || logicalTo p == numeric_limits<int>::max()) 3198 if (logicalBottom < 0 || logicalBottom < logicalTop || logicalTo p == numeric_limits<int>::max())
3199 logicalBottom = numeric_limits<int>::max(); 3199 logicalBottom = numeric_limits<int>::max();
3200 else { 3200 else {
3201 // Special-case zero- and less-than-zero-height floats: thos e don't touch 3201 // Special-case zero- and less-than-zero-height floats: thos e don't touch
3202 // the line that they're on, but it still needs to be dirtie d. This is 3202 // the line that they're on, but it still needs to be dirtie d. This is
3203 // accomplished by pretending they have a height of 1. 3203 // accomplished by pretending they have a height of 1.
3204 logicalBottom = max(logicalBottom, logicalTop + 1); 3204 logicalBottom = max(logicalBottom, logicalTop + 1);
3205 } 3205 }
3206 if (r->m_originatingLine) { 3206 if (r->m_originatingLine) {
3207 ASSERT(r->m_originatingLine->renderer() == this); 3207 if (!selfNeedsLayout()) {
3208 r->m_originatingLine->markDirty(); 3208 ASSERT(r->m_originatingLine->renderer() == this);
3209 r->m_originatingLine->markDirty();
3210 }
3209 #if !ASSERT_DISABLED 3211 #if !ASSERT_DISABLED
3210 r->m_originatingLine = 0; 3212 r->m_originatingLine = 0;
3211 #endif 3213 #endif
3212 } 3214 }
3213 markLinesDirtyInBlockRange(0, logicalBottom); 3215 markLinesDirtyInBlockRange(0, logicalBottom);
3214 } 3216 }
3215 m_floatingObjects->decreaseObjectsCount(r->type()); 3217 m_floatingObjects->decreaseObjectsCount(r->type());
3216 floatingObjectSet.remove(it); 3218 floatingObjectSet.remove(it);
3217 ASSERT(!r->m_originatingLine); 3219 ASSERT(!r->m_originatingLine);
3218 delete r; 3220 delete r;
(...skipping 453 matching lines...) Expand 10 before | Expand all | Expand 10 after
3672 int oldLogicalBottom = logicalBottomForFloat(oldFloatingObje ct); 3674 int oldLogicalBottom = logicalBottomForFloat(oldFloatingObje ct);
3673 if (logicalWidthForFloat(f) != logicalWidthForFloat(oldFloat ingObject) || logicalLeftForFloat(f) != logicalLeftForFloat(oldFloatingObject)) { 3675 if (logicalWidthForFloat(f) != logicalWidthForFloat(oldFloat ingObject) || logicalLeftForFloat(f) != logicalLeftForFloat(oldFloatingObject)) {
3674 changeLogicalTop = 0; 3676 changeLogicalTop = 0;
3675 changeLogicalBottom = max(changeLogicalBottom, max(logic alBottom, oldLogicalBottom)); 3677 changeLogicalBottom = max(changeLogicalBottom, max(logic alBottom, oldLogicalBottom));
3676 } else if (logicalBottom != oldLogicalBottom) { 3678 } else if (logicalBottom != oldLogicalBottom) {
3677 changeLogicalTop = min(changeLogicalTop, min(logicalBott om, oldLogicalBottom)); 3679 changeLogicalTop = min(changeLogicalTop, min(logicalBott om, oldLogicalBottom));
3678 changeLogicalBottom = max(changeLogicalBottom, max(logic alBottom, oldLogicalBottom)); 3680 changeLogicalBottom = max(changeLogicalBottom, max(logic alBottom, oldLogicalBottom));
3679 } 3681 }
3680 3682
3681 floatMap.remove(f->m_renderer); 3683 floatMap.remove(f->m_renderer);
3682 if (oldFloatingObject->m_originatingLine) { 3684 if (oldFloatingObject->m_originatingLine && !selfNeedsLayout ()) {
3683 ASSERT(oldFloatingObject->m_originatingLine->renderer() == this); 3685 ASSERT(oldFloatingObject->m_originatingLine->renderer() == this);
3684 oldFloatingObject->m_originatingLine->markDirty(); 3686 oldFloatingObject->m_originatingLine->markDirty();
3685 } 3687 }
3686 delete oldFloatingObject; 3688 delete oldFloatingObject;
3687 } else { 3689 } else {
3688 changeLogicalTop = 0; 3690 changeLogicalTop = 0;
3689 changeLogicalBottom = max(changeLogicalBottom, logicalBottom ); 3691 changeLogicalBottom = max(changeLogicalBottom, logicalBottom );
3690 } 3692 }
3691 } 3693 }
3692 } 3694 }
(...skipping 2707 matching lines...) Expand 10 before | Expand all | Expand 10 after
6400 void RenderBlock::showLineTreeAndMark(const InlineBox* markedBox1, const char* m arkedLabel1, const InlineBox* markedBox2, const char* markedLabel2, const Render Object* obj) const 6402 void RenderBlock::showLineTreeAndMark(const InlineBox* markedBox1, const char* m arkedLabel1, const InlineBox* markedBox2, const char* markedLabel2, const Render Object* obj) const
6401 { 6403 {
6402 showRenderObject(); 6404 showRenderObject();
6403 for (const RootInlineBox* root = firstRootBox(); root; root = root->nextRoot Box()) 6405 for (const RootInlineBox* root = firstRootBox(); root; root = root->nextRoot Box())
6404 root->showLineTreeAndMark(markedBox1, markedLabel1, markedBox2, markedLa bel2, obj, 1); 6406 root->showLineTreeAndMark(markedBox1, markedLabel1, markedBox2, markedLa bel2, obj, 1);
6405 } 6407 }
6406 6408
6407 #endif 6409 #endif
6408 6410
6409 } // namespace WebCore 6411 } // namespace WebCore
OLDNEW
« no previous file with comments | « LayoutTests/fast/block/float/float-originating-line-deleted-crash-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698