OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef PaintPropertyTreeBuilder_h | 5 #ifndef PaintPropertyTreeBuilder_h |
6 #define PaintPropertyTreeBuilder_h | 6 #define PaintPropertyTreeBuilder_h |
7 | 7 |
8 #include "platform/geometry/LayoutPoint.h" | 8 #include "platform/geometry/LayoutPoint.h" |
9 #include "platform/graphics/paint/ClipPaintPropertyNode.h" | 9 #include "platform/graphics/paint/ClipPaintPropertyNode.h" |
10 #include "platform/graphics/paint/EffectPaintPropertyNode.h" | 10 #include "platform/graphics/paint/EffectPaintPropertyNode.h" |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
58 // These additional contexts normally pass through untouched, and are only | 58 // These additional contexts normally pass through untouched, and are only |
59 // copied from the main context when the current element serves as the | 59 // copied from the main context when the current element serves as the |
60 // containing block of corresponding positioned descendants. Overflow clips | 60 // containing block of corresponding positioned descendants. Overflow clips |
61 // are also inherited by containing block tree instead of DOM tree, thus they | 61 // are also inherited by containing block tree instead of DOM tree, thus they |
62 // are included in the additional context too. | 62 // are included in the additional context too. |
63 ContainingBlockContext absolutePosition; | 63 ContainingBlockContext absolutePosition; |
64 const LayoutObject* containerForAbsolutePosition = nullptr; | 64 const LayoutObject* containerForAbsolutePosition = nullptr; |
65 | 65 |
66 ContainingBlockContext fixedPosition; | 66 ContainingBlockContext fixedPosition; |
67 | 67 |
68 // This is the same as current.paintOffset except when a floating object has | 68 // These are the same as current.paintOffset except when a floating object's |
69 // non-block ancestors under its containing block. Paint offsets of the | 69 // parent is not a container. Paint offsets of the non-container ancestors |
70 // non-block ancestors should not be accumulated for the floating object. | 70 // should not be accumulated for the floating object. |
71 LayoutPoint paintOffsetForFloat; | 71 LayoutPoint paintOffsetForNonStackedFloat; |
| 72 LayoutPoint paintOffsetForStackedFloat; |
72 | 73 |
73 // The effect hierarchy is applied by the stacking context tree. It is | 74 // The effect hierarchy is applied by the stacking context tree. It is |
74 // guaranteed that every DOM descendant is also a stacking context descendant. | 75 // guaranteed that every DOM descendant is also a stacking context descendant. |
75 // Therefore, we don't need extra bookkeeping for effect nodes and can | 76 // Therefore, we don't need extra bookkeeping for effect nodes and can |
76 // generate the effect tree from a DOM-order traversal. | 77 // generate the effect tree from a DOM-order traversal. |
77 const EffectPaintPropertyNode* currentEffect = nullptr; | 78 const EffectPaintPropertyNode* currentEffect = nullptr; |
78 // Some effects are spatial, i.e. may refer to input pixels outside of output | 79 // Some effects are spatial, i.e. may refer to input pixels outside of output |
79 // clip. The cull rect for its input shall be derived from its output clip. | 80 // clip. The cull rect for its input shall be derived from its output clip. |
80 // This variable represents the input cull of current effect, also serves as | 81 // This variable represents the input cull of current effect, also serves as |
81 // output clip of child effects that don't have a hard clip. | 82 // output clip of child effects that don't have a hard clip. |
(...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
146 const LayoutObject&, | 147 const LayoutObject&, |
147 PaintPropertyTreeBuilderContext&); | 148 PaintPropertyTreeBuilderContext&); |
148 ALWAYS_INLINE static void updateOutOfFlowContext( | 149 ALWAYS_INLINE static void updateOutOfFlowContext( |
149 const LayoutObject&, | 150 const LayoutObject&, |
150 PaintPropertyTreeBuilderContext&); | 151 PaintPropertyTreeBuilderContext&); |
151 }; | 152 }; |
152 | 153 |
153 } // namespace blink | 154 } // namespace blink |
154 | 155 |
155 #endif // PaintPropertyTreeBuilder_h | 156 #endif // PaintPropertyTreeBuilder_h |
OLD | NEW |