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

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

Issue 789433006: [New Multicolumn] Let a spanner's containing block be the multicol container. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Compiling release: paint invalidation state is cleared in the super class anyway. Created 6 years 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/RenderBox.h ('k') | Source/core/rendering/RenderFlowThread.h » ('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) 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) 2005 Allan Sandfeld Jensen (kde@carewolf.com) 4 * (C) 2005 Allan Sandfeld Jensen (kde@carewolf.com)
5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com) 5 * (C) 2005, 2006 Samuel Weinig (sam.weinig@gmail.com)
6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv ed. 6 * Copyright (C) 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv ed.
7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved. 7 * Copyright (C) 2013 Adobe Systems Incorporated. All rights reserved.
8 * 8 *
9 * This library is free software; you can redistribute it and/or 9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Library General Public 10 * modify it under the terms of the GNU Library General Public
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
45 #include "core/rendering/HitTestResult.h" 45 #include "core/rendering/HitTestResult.h"
46 #include "core/rendering/PaintInfo.h" 46 #include "core/rendering/PaintInfo.h"
47 #include "core/rendering/RenderDeprecatedFlexibleBox.h" 47 #include "core/rendering/RenderDeprecatedFlexibleBox.h"
48 #include "core/rendering/RenderFlexibleBox.h" 48 #include "core/rendering/RenderFlexibleBox.h"
49 #include "core/rendering/RenderGeometryMap.h" 49 #include "core/rendering/RenderGeometryMap.h"
50 #include "core/rendering/RenderGrid.h" 50 #include "core/rendering/RenderGrid.h"
51 #include "core/rendering/RenderInline.h" 51 #include "core/rendering/RenderInline.h"
52 #include "core/rendering/RenderLayer.h" 52 #include "core/rendering/RenderLayer.h"
53 #include "core/rendering/RenderListBox.h" 53 #include "core/rendering/RenderListBox.h"
54 #include "core/rendering/RenderListMarker.h" 54 #include "core/rendering/RenderListMarker.h"
55 #include "core/rendering/RenderMultiColumnSpannerPlaceholder.h"
55 #include "core/rendering/RenderTableCell.h" 56 #include "core/rendering/RenderTableCell.h"
56 #include "core/rendering/RenderView.h" 57 #include "core/rendering/RenderView.h"
57 #include "core/rendering/compositing/RenderLayerCompositor.h" 58 #include "core/rendering/compositing/RenderLayerCompositor.h"
58 #include "platform/LengthFunctions.h" 59 #include "platform/LengthFunctions.h"
59 #include "platform/geometry/FloatQuad.h" 60 #include "platform/geometry/FloatQuad.h"
60 #include "platform/geometry/TransformState.h" 61 #include "platform/geometry/TransformState.h"
61 #include <algorithm> 62 #include <algorithm>
62 #include <math.h> 63 #include <math.h>
63 64
64 namespace blink { 65 namespace blink {
(...skipping 27 matching lines...) Expand all
92 93
93 RenderBox::RenderBox(ContainerNode* node) 94 RenderBox::RenderBox(ContainerNode* node)
94 : RenderBoxModelObject(node) 95 : RenderBoxModelObject(node)
95 , m_intrinsicContentLogicalHeight(-1) 96 , m_intrinsicContentLogicalHeight(-1)
96 , m_minPreferredLogicalWidth(-1) 97 , m_minPreferredLogicalWidth(-1)
97 , m_maxPreferredLogicalWidth(-1) 98 , m_maxPreferredLogicalWidth(-1)
98 { 99 {
99 setIsBox(); 100 setIsBox();
100 } 101 }
101 102
103 void RenderBox::willBeRemovedFromTree()
104 {
105 if (m_rareData && m_rareData->m_spannerPlaceholder) {
106 m_rareData->m_spannerPlaceholder->spannerWillBeRemoved();
107 m_rareData->m_spannerPlaceholder = 0;
108 }
109 RenderBoxModelObject::willBeRemovedFromTree();
110 }
111
102 void RenderBox::willBeDestroyed() 112 void RenderBox::willBeDestroyed()
103 { 113 {
104 clearOverrideSize(); 114 clearOverrideSize();
105 clearContainingBlockOverrideSize(); 115 clearContainingBlockOverrideSize();
106 116
107 RenderBlock::removePercentHeightDescendantIfNeeded(this); 117 RenderBlock::removePercentHeightDescendantIfNeeded(this);
108 118
109 ShapeOutsideInfo::removeInfo(*this); 119 ShapeOutsideInfo::removeInfo(*this);
110 120
111 RenderBoxModelObject::willBeDestroyed(); 121 RenderBoxModelObject::willBeDestroyed();
(...skipping 1539 matching lines...) Expand 10 before | Expand all | Expand 10 after
1651 { 1661 {
1652 if (inlineBoxWrapper()) { 1662 if (inlineBoxWrapper()) {
1653 if (!documentBeingDestroyed()) 1663 if (!documentBeingDestroyed())
1654 inlineBoxWrapper()->remove(); 1664 inlineBoxWrapper()->remove();
1655 inlineBoxWrapper()->destroy(); 1665 inlineBoxWrapper()->destroy();
1656 ASSERT(m_rareData); 1666 ASSERT(m_rareData);
1657 m_rareData->m_inlineBoxWrapper = 0; 1667 m_rareData->m_inlineBoxWrapper = 0;
1658 } 1668 }
1659 } 1669 }
1660 1670
1671 void RenderBox::setSpannerPlaceholder(RenderMultiColumnSpannerPlaceholder& place holder)
1672 {
1673 RELEASE_ASSERT(!m_rareData || !m_rareData->m_spannerPlaceholder); // not exp ected to change directly from one spanner to another.
1674 ensureRareData().m_spannerPlaceholder = &placeholder;
1675 }
1676
1677 void RenderBox::clearSpannerPlaceholder()
1678 {
1679 if (!m_rareData)
1680 return;
1681 m_rareData->m_spannerPlaceholder = 0;
1682 }
1683
1661 LayoutRect RenderBox::clippedOverflowRectForPaintInvalidation(const RenderLayerM odelObject* paintInvalidationContainer, const PaintInvalidationState* paintInval idationState) const 1684 LayoutRect RenderBox::clippedOverflowRectForPaintInvalidation(const RenderLayerM odelObject* paintInvalidationContainer, const PaintInvalidationState* paintInval idationState) const
1662 { 1685 {
1663 if (style()->visibility() != VISIBLE) { 1686 if (style()->visibility() != VISIBLE) {
1664 RenderLayer* layer = enclosingLayer(); 1687 RenderLayer* layer = enclosingLayer();
1665 layer->updateDescendantDependentFlags(); 1688 layer->updateDescendantDependentFlags();
1666 if (layer->subtreeIsInvisible()) 1689 if (layer->subtreeIsInvisible())
1667 return LayoutRect(); 1690 return LayoutRect();
1668 } 1691 }
1669 1692
1670 LayoutRect r = visualOverflowRect(); 1693 LayoutRect r = visualOverflowRect();
(...skipping 2758 matching lines...) Expand 10 before | Expand all | Expand 10 after
4429 computedValues.m_margins.m_end = marginEnd(); 4452 computedValues.m_margins.m_end = marginEnd();
4430 4453
4431 setLogicalTop(oldLogicalTop); 4454 setLogicalTop(oldLogicalTop);
4432 setLogicalWidth(oldLogicalWidth); 4455 setLogicalWidth(oldLogicalWidth);
4433 setLogicalLeft(oldLogicalLeft); 4456 setLogicalLeft(oldLogicalLeft);
4434 setMarginLeft(oldMarginLeft); 4457 setMarginLeft(oldMarginLeft);
4435 setMarginRight(oldMarginRight); 4458 setMarginRight(oldMarginRight);
4436 } 4459 }
4437 4460
4438 } // namespace blink 4461 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/rendering/RenderBox.h ('k') | Source/core/rendering/RenderFlowThread.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698