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

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

Issue 12283026: Merge 142657 (Closed) Base URL: http://svn.webkit.org/repository/webkit/branches/chromium/1410/
Patch Set: Created 7 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/multicol/span/list-multi-column-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, 2011 Apple Inc. All rights reserved. 5 * Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All rights 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 511 matching lines...) Expand 10 before | Expand all | Expand 10 after
522 } 522 }
523 523
524 RenderBlock* RenderBlock::containingColumnsBlock(bool allowAnonymousColumnBlock) 524 RenderBlock* RenderBlock::containingColumnsBlock(bool allowAnonymousColumnBlock)
525 { 525 {
526 RenderBlock* firstChildIgnoringAnonymousWrappers = 0; 526 RenderBlock* firstChildIgnoringAnonymousWrappers = 0;
527 for (RenderObject* curr = this; curr; curr = curr->parent()) { 527 for (RenderObject* curr = this; curr; curr = curr->parent()) {
528 if (!curr->isRenderBlock() || curr->isFloatingOrOutOfFlowPositioned() || curr->isTableCell() || curr->isRoot() || curr->isRenderView() || curr->hasOverf lowClip() 528 if (!curr->isRenderBlock() || curr->isFloatingOrOutOfFlowPositioned() || curr->isTableCell() || curr->isRoot() || curr->isRenderView() || curr->hasOverf lowClip()
529 || curr->isInlineBlockOrInlineTable()) 529 || curr->isInlineBlockOrInlineTable())
530 return 0; 530 return 0;
531 531
532 // FIXME: Table manages its own table parts, most of which are RenderBox es. 532 // FIXME: Tables, RenderButtons, and RenderListItems all do special mana gement
533 // Multi-column code cannot handle splitting the flow in table. Disablin g it 533 // of their children that breaks when the flow is split through them. Di sabling
534 // to prevent crashes. 534 // multi-column for them to avoid this problem.
535 // Similarly, RenderButton maintains an anonymous block child and overri des 535 if (curr->isTable() || curr->isRenderButton() || curr->isListItem())
536 // addChild() to prevent itself from having additional direct children. This
537 // causes problems for split flows.
538 if (curr->isTable() || curr->isRenderButton())
539 return 0; 536 return 0;
540 537
541 RenderBlock* currBlock = toRenderBlock(curr); 538 RenderBlock* currBlock = toRenderBlock(curr);
542 if (!currBlock->createsAnonymousWrapper()) 539 if (!currBlock->createsAnonymousWrapper())
543 firstChildIgnoringAnonymousWrappers = currBlock; 540 firstChildIgnoringAnonymousWrappers = currBlock;
544 541
545 if (currBlock->style()->specifiesColumns() && (allowAnonymousColumnBlock || !currBlock->isAnonymousColumnsBlock())) 542 if (currBlock->style()->specifiesColumns() && (allowAnonymousColumnBlock || !currBlock->isAnonymousColumnsBlock()))
546 return firstChildIgnoringAnonymousWrappers; 543 return firstChildIgnoringAnonymousWrappers;
547 544
548 if (currBlock->isAnonymousColumnSpanBlock()) 545 if (currBlock->isAnonymousColumnSpanBlock())
(...skipping 7302 matching lines...) Expand 10 before | Expand all | Expand 10 after
7851 { 7848 {
7852 memoryInstrumentation->addRootObject(gColumnInfoMap, WebCoreMemoryTypes::Ren deringStructures); 7849 memoryInstrumentation->addRootObject(gColumnInfoMap, WebCoreMemoryTypes::Ren deringStructures);
7853 memoryInstrumentation->addRootObject(gPositionedDescendantsMap, WebCoreMemor yTypes::RenderingStructures); 7850 memoryInstrumentation->addRootObject(gPositionedDescendantsMap, WebCoreMemor yTypes::RenderingStructures);
7854 memoryInstrumentation->addRootObject(gPercentHeightDescendantsMap, WebCoreMe moryTypes::RenderingStructures); 7851 memoryInstrumentation->addRootObject(gPercentHeightDescendantsMap, WebCoreMe moryTypes::RenderingStructures);
7855 memoryInstrumentation->addRootObject(gPositionedContainerMap, WebCoreMemoryT ypes::RenderingStructures); 7852 memoryInstrumentation->addRootObject(gPositionedContainerMap, WebCoreMemoryT ypes::RenderingStructures);
7856 memoryInstrumentation->addRootObject(gPercentHeightContainerMap, WebCoreMemo ryTypes::RenderingStructures); 7853 memoryInstrumentation->addRootObject(gPercentHeightContainerMap, WebCoreMemo ryTypes::RenderingStructures);
7857 memoryInstrumentation->addRootObject(gDelayedUpdateScrollInfoSet, WebCoreMem oryTypes::RenderingStructures); 7854 memoryInstrumentation->addRootObject(gDelayedUpdateScrollInfoSet, WebCoreMem oryTypes::RenderingStructures);
7858 } 7855 }
7859 7856
7860 } // namespace WebCore 7857 } // namespace WebCore
OLDNEW
« no previous file with comments | « LayoutTests/fast/multicol/span/list-multi-column-crash-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698