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

Side by Side Diff: third_party/WebKit/Source/core/layout/ng/ng_block_layout_algorithm.h

Issue 2719373002: [LayoutNG] Move NGConstraintSpaceBuilder off Oilpan and DISALLOW_NEW. (Closed)
Patch Set: rebase Created 3 years, 9 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 | « no previous file | third_party/WebKit/Source/core/layout/ng/ng_block_layout_algorithm.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 NGBlockLayoutAlgorithm_h 5 #ifndef NGBlockLayoutAlgorithm_h
6 #define NGBlockLayoutAlgorithm_h 6 #define NGBlockLayoutAlgorithm_h
7 7
8 #include "core/CoreExport.h" 8 #include "core/CoreExport.h"
9 #include "core/layout/ng/ng_block_node.h" 9 #include "core/layout/ng/ng_block_node.h"
10 #include "core/layout/ng/ng_break_token.h" 10 #include "core/layout/ng/ng_break_token.h"
11 #include "core/layout/ng/ng_constraint_space_builder.h"
11 #include "core/layout/ng/ng_fragment_builder.h" 12 #include "core/layout/ng/ng_fragment_builder.h"
12 #include "core/layout/ng/ng_layout_algorithm.h" 13 #include "core/layout/ng/ng_layout_algorithm.h"
13 #include "core/layout/ng/ng_units.h" 14 #include "core/layout/ng/ng_units.h"
14 #include "wtf/RefPtr.h" 15 #include "wtf/RefPtr.h"
15 16
16 namespace blink { 17 namespace blink {
17 18
18 class ComputedStyle; 19 class ComputedStyle;
19 class NGBlockBreakToken; 20 class NGBlockBreakToken;
20 class NGConstraintSpace; 21 class NGConstraintSpace;
21 class NGConstraintSpaceBuilder;
22 class NGInlineNode; 22 class NGInlineNode;
23 class NGLayoutResult; 23 class NGLayoutResult;
24 24
25 // A class for general block layout (e.g. a <div> with no special style). 25 // A class for general block layout (e.g. a <div> with no special style).
26 // Lays out the children in sequence. 26 // Lays out the children in sequence.
27 class CORE_EXPORT NGBlockLayoutAlgorithm : public NGLayoutAlgorithm { 27 class CORE_EXPORT NGBlockLayoutAlgorithm : public NGLayoutAlgorithm {
28 public: 28 public:
29 // Default constructor. 29 // Default constructor.
30 // @param node The input node to perform layout upon. 30 // @param node The input node to perform layout upon.
31 // @param space The constraint space which the algorithm should generate a 31 // @param space The constraint space which the algorithm should generate a
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
75 } 75 }
76 76
77 const ComputedStyle& Style() const { return node_->Style(); } 77 const ComputedStyle& Style() const { return node_->Style(); }
78 78
79 Persistent<NGBlockNode> node_; 79 Persistent<NGBlockNode> node_;
80 Persistent<NGConstraintSpace> constraint_space_; 80 Persistent<NGConstraintSpace> constraint_space_;
81 81
82 // The break token from which we are currently resuming layout. 82 // The break token from which we are currently resuming layout.
83 Persistent<NGBlockBreakToken> break_token_; 83 Persistent<NGBlockBreakToken> break_token_;
84 84
85 std::unique_ptr<NGFragmentBuilder> builder_; 85 NGFragmentBuilder builder_;
86 Persistent<NGConstraintSpaceBuilder> space_builder_; 86 NGConstraintSpaceBuilder space_builder_;
87 87
88 NGBoxStrut border_and_padding_; 88 NGBoxStrut border_and_padding_;
89 LayoutUnit content_size_; 89 LayoutUnit content_size_;
90 LayoutUnit max_inline_size_; 90 LayoutUnit max_inline_size_;
91 // MarginStrut for the previous child. 91 // MarginStrut for the previous child.
92 NGMarginStrut curr_margin_strut_; 92 NGMarginStrut curr_margin_strut_;
93 NGLogicalOffset curr_bfc_offset_; 93 NGLogicalOffset curr_bfc_offset_;
94 NGBoxStrut curr_child_margins_; 94 NGBoxStrut curr_child_margins_;
95 }; 95 };
96 96
97 } // namespace blink 97 } // namespace blink
98 98
99 #endif // NGBlockLayoutAlgorithm_h 99 #endif // NGBlockLayoutAlgorithm_h
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/layout/ng/ng_block_layout_algorithm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698