Chromium Code Reviews| 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" |
| 11 #include "platform/graphics/paint/ScrollPaintPropertyNode.h" | |
| 11 #include "platform/graphics/paint/TransformPaintPropertyNode.h" | 12 #include "platform/graphics/paint/TransformPaintPropertyNode.h" |
| 12 #include "wtf/RefPtr.h" | 13 #include "wtf/RefPtr.h" |
| 13 | 14 |
| 14 namespace blink { | 15 namespace blink { |
| 15 | 16 |
| 16 class FrameView; | 17 class FrameView; |
| 17 class LayoutObject; | 18 class LayoutObject; |
| 18 class ObjectPaintProperties; | 19 class ObjectPaintProperties; |
| 19 | 20 |
| 20 // The context for PaintPropertyTreeBuilder. | 21 // The context for PaintPropertyTreeBuilder. |
| (...skipping 15 matching lines...) Expand all Loading... | |
| 36 // to immediate children. | 37 // to immediate children. |
| 37 bool shouldFlattenInheritedTransform = false; | 38 bool shouldFlattenInheritedTransform = false; |
| 38 // Rendering context for 3D sorting. See | 39 // Rendering context for 3D sorting. See |
| 39 // TransformPaintPropertyNode::renderingContextID. | 40 // TransformPaintPropertyNode::renderingContextID. |
| 40 unsigned renderingContextID = 0; | 41 unsigned renderingContextID = 0; |
| 41 // The clip node describes the accumulated raster clip for the current s ubtree. | 42 // The clip node describes the accumulated raster clip for the current s ubtree. |
| 42 // Note that the computed raster region in canvas space for a clip node is independent from | 43 // Note that the computed raster region in canvas space for a clip node is independent from |
| 43 // the transform and paint offset above. Also the actual raster region m ay be affected | 44 // the transform and paint offset above. Also the actual raster region m ay be affected |
| 44 // by layerization and occlusion tracking. | 45 // by layerization and occlusion tracking. |
| 45 const ClipPaintPropertyNode* clip = nullptr; | 46 const ClipPaintPropertyNode* clip = nullptr; |
| 47 // The scroll node contains information for compositor-thread scrolling such as the | |
|
chrishtr
2016/09/08 20:43:59
remove compositor-thread
pdr.
2016/09/08 23:16:26
Done
| |
| 48 // scrolling hierarchy, the extent that can be scrolled, etc. Because sc roll nodes reference | |
| 49 // a scroll offset transform, scroll nodes should be updated if the tran sform tree changes. | |
| 50 const ScrollPaintPropertyNode* scroll = nullptr; | |
| 46 }; | 51 }; |
| 47 | 52 |
| 48 ContainingBlockContext current; | 53 ContainingBlockContext current; |
| 49 | 54 |
| 50 // Separate context for out-of-flow positioned and fixed positioned elements are needed | 55 // Separate context for out-of-flow positioned and fixed positioned elements are needed |
| 51 // because they don't use DOM parent as their containing block. | 56 // because they don't use DOM parent as their containing block. |
| 52 // These additional contexts normally pass through untouched, and are only c opied from | 57 // These additional contexts normally pass through untouched, and are only c opied from |
| 53 // the main context when the current element serves as the containing block of corresponding | 58 // the main context when the current element serves as the containing block of corresponding |
| 54 // positioned descendants. | 59 // positioned descendants. |
| 55 // Overflow clips are also inherited by containing block tree instead of DOM tree, thus they | 60 // Overflow clips are also inherited by containing block tree instead of DOM tree, thus they |
| (...skipping 23 matching lines...) Expand all Loading... | |
| 79 private: | 84 private: |
| 80 static void updatePaintOffsetTranslation(const LayoutObject&, PaintPropertyT reeBuilderContext&); | 85 static void updatePaintOffsetTranslation(const LayoutObject&, PaintPropertyT reeBuilderContext&); |
| 81 static void updateTransform(const LayoutObject&, PaintPropertyTreeBuilderCon text&); | 86 static void updateTransform(const LayoutObject&, PaintPropertyTreeBuilderCon text&); |
| 82 static void updateEffect(const LayoutObject&, PaintPropertyTreeBuilderContex t&); | 87 static void updateEffect(const LayoutObject&, PaintPropertyTreeBuilderContex t&); |
| 83 static void updateCssClip(const LayoutObject&, PaintPropertyTreeBuilderConte xt&); | 88 static void updateCssClip(const LayoutObject&, PaintPropertyTreeBuilderConte xt&); |
| 84 static void updateLocalBorderBoxContext(const LayoutObject&, PaintPropertyTr eeBuilderContext&); | 89 static void updateLocalBorderBoxContext(const LayoutObject&, PaintPropertyTr eeBuilderContext&); |
| 85 static void updateScrollbarPaintOffset(const LayoutObject&, const PaintPrope rtyTreeBuilderContext&); | 90 static void updateScrollbarPaintOffset(const LayoutObject&, const PaintPrope rtyTreeBuilderContext&); |
| 86 static void updateOverflowClip(const LayoutObject&, PaintPropertyTreeBuilder Context&); | 91 static void updateOverflowClip(const LayoutObject&, PaintPropertyTreeBuilder Context&); |
| 87 static void updatePerspective(const LayoutObject&, PaintPropertyTreeBuilderC ontext&); | 92 static void updatePerspective(const LayoutObject&, PaintPropertyTreeBuilderC ontext&); |
| 88 static void updateSvgLocalToBorderBoxTransform(const LayoutObject&, PaintPro pertyTreeBuilderContext&); | 93 static void updateSvgLocalToBorderBoxTransform(const LayoutObject&, PaintPro pertyTreeBuilderContext&); |
| 89 static void updateScrollTranslation(const LayoutObject&, PaintPropertyTreeBu ilderContext&); | 94 static void updateScrollAndScrollTranslation(const LayoutObject&, PaintPrope rtyTreeBuilderContext&); |
| 90 static void updateOutOfFlowContext(const LayoutObject&, PaintPropertyTreeBui lderContext&); | 95 static void updateOutOfFlowContext(const LayoutObject&, PaintPropertyTreeBui lderContext&); |
| 91 }; | 96 }; |
| 92 | 97 |
| 93 } // namespace blink | 98 } // namespace blink |
| 94 | 99 |
| 95 #endif // PaintPropertyTreeBuilder_h | 100 #endif // PaintPropertyTreeBuilder_h |
| OLD | NEW |