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

Side by Side Diff: Source/core/paint/DeprecatedPaintLayerStackingNode.h

Issue 1327483003: Add documentation to 2 DeprecatedPaintLayer objects (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 3 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 | Annotate | Revision Log
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2003, 2009, 2012 Apple Inc. All rights reserved. 2 * Copyright (C) 2003, 2009, 2012 Apple Inc. All rights reserved.
3 * Copyright (C) 2013 Intel Corporation. All rights reserved. 3 * Copyright (C) 2013 Intel Corporation. All rights reserved.
4 * 4 *
5 * Portions are Copyright (C) 1998 Netscape Communications Corporation. 5 * Portions are Copyright (C) 1998 Netscape Communications Corporation.
6 * 6 *
7 * Other contributors: 7 * Other contributors:
8 * Robert O'Callahan <roc+@cs.cmu.edu> 8 * Robert O'Callahan <roc+@cs.cmu.edu>
9 * David Baron <dbaron@fas.harvard.edu> 9 * David Baron <dbaron@fas.harvard.edu>
10 * Christian Biesinger <cbiesinger@web.de> 10 * Christian Biesinger <cbiesinger@web.de>
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 #include "wtf/OwnPtr.h" 51 #include "wtf/OwnPtr.h"
52 #include "wtf/Vector.h" 52 #include "wtf/Vector.h"
53 53
54 namespace blink { 54 namespace blink {
55 55
56 class DeprecatedPaintLayer; 56 class DeprecatedPaintLayer;
57 class DeprecatedPaintLayerCompositor; 57 class DeprecatedPaintLayerCompositor;
58 class ComputedStyle; 58 class ComputedStyle;
59 class LayoutBoxModelObject; 59 class LayoutBoxModelObject;
60 60
61 // DeprecatedPaintLayerStackingNode represents anything that is treated as a
62 // stacking context.
63 //
64 // Stacking contexts are the basis for the CSS painting algorithm. The paint
65 // order is determined by walking stacking contexts (or elements treated like a
66 // stacking context like positioned objects or floats) in an order defined by
67 // ‘z-index’. This walk is interleaved with content that is not a stacking.
68 // context. See CSS 2.1 appendix e for the actual algorithm
mstensho (USE GERRIT) 2015/09/01 18:59:06 Might want to capitalize that "e".
Julien - ping for review 2015/09/03 14:25:54 D-O-N-E!
69 // http://www.w3.org/TR/CSS21/zindex.html
70 // See also DeprecatedPaintLayerPainter (in particular paintLayerContents) for
71 // our implementation of the walk.
72 //
73 // Stacking contexts form a subtree over the layout tree. Ideally we would want
74 // this class to be a node in this tree but there are potential issues with
mstensho (USE GERRIT) 2015/09/01 18:59:06 "objects of this class to be nodes in this tree"?
Julien - ping for review 2015/09/03 14:25:54 sgtm.
75 // stale pointers so we rely on DeprecatedPaintLayer's tree structure.
76 //
77 // This class's purpose is to cache the z-order lists for painting and
eae 2015/09/01 18:08:59 They're used to represent and not just cache the s
Julien - ping for review 2015/09/03 14:25:54 Good catch. Amended the description of the class t
78 // hit-testing.
79 //
80 // To implement any zorder list iterations, use
mstensho (USE GERRIT) 2015/09/01 18:59:06 "z-order"
Julien - ping for review 2015/09/03 14:25:54 changed.
81 // DeprecatedPaintLayerStackingNodeIterator and
82 // DeprecatedPaintLayerStackingNodeReverseIterator.
61 class CORE_EXPORT DeprecatedPaintLayerStackingNode { 83 class CORE_EXPORT DeprecatedPaintLayerStackingNode {
62 WTF_MAKE_FAST_ALLOCATED(DeprecatedPaintLayerStackingNode); 84 WTF_MAKE_FAST_ALLOCATED(DeprecatedPaintLayerStackingNode);
63 WTF_MAKE_NONCOPYABLE(DeprecatedPaintLayerStackingNode); 85 WTF_MAKE_NONCOPYABLE(DeprecatedPaintLayerStackingNode);
64 public: 86 public:
65 explicit DeprecatedPaintLayerStackingNode(LayoutBoxModelObject&); 87 explicit DeprecatedPaintLayerStackingNode(LayoutBoxModelObject&);
66 ~DeprecatedPaintLayerStackingNode(); 88 ~DeprecatedPaintLayerStackingNode();
67 89
68 int zIndex() const { return layoutObject().style()->zIndex(); } 90 int zIndex() const { return layoutObject().style()->zIndex(); }
69 91
70 bool isStackingContext() const { return layoutObject().style()->isStackingCo ntext(); } 92 bool isStackingContext() const { return layoutObject().style()->isStackingCo ntext(); }
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
193 215
194 private: 216 private:
195 DeprecatedPaintLayerStackingNode* m_stackingNode; 217 DeprecatedPaintLayerStackingNode* m_stackingNode;
196 bool m_previousMutationAllowedState; 218 bool m_previousMutationAllowedState;
197 }; 219 };
198 #endif 220 #endif
199 221
200 } // namespace blink 222 } // namespace blink
201 223
202 #endif // DeprecatedPaintLayerStackingNode_h 224 #endif // DeprecatedPaintLayerStackingNode_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698