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

Side by Side Diff: third_party/WebKit/Source/core/layout/ng/ng_layout_opportunity_tree_node.cc

Issue 2462413002: Reland of Use NGLogicalRect instead of NGExclusion for exclusions. (Closed)
Patch Set: Created 4 years, 1 month 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
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 #include "core/layout/ng/ng_layout_opportunity_tree_node.h" 5 #include "core/layout/ng/ng_layout_opportunity_tree_node.h"
6 6
7 #include "platform/heap/Handle.h" 7 #include "platform/heap/Handle.h"
8 #include "core/layout/ng/ng_constraint_space.h" 8 #include "core/layout/ng/ng_constraint_space.h"
9 9
10 namespace blink { 10 namespace blink {
11 11
12 NGLayoutOpportunityTreeNode::NGLayoutOpportunityTreeNode( 12 NGLayoutOpportunityTreeNode::NGLayoutOpportunityTreeNode(
13 const NGLogicalRect opportunity) 13 const NGLogicalRect opportunity)
14 : opportunity(opportunity) { 14 : opportunity(opportunity), exclusion(nullptr) {
15 exclusion_edge.start = opportunity.offset.inline_offset; 15 exclusion_edge.start = opportunity.offset.inline_offset;
16 exclusion_edge.end = exclusion_edge.start + opportunity.size.inline_size; 16 exclusion_edge.end = exclusion_edge.start + opportunity.size.inline_size;
17 } 17 }
18 18
19 NGLayoutOpportunityTreeNode::NGLayoutOpportunityTreeNode( 19 NGLayoutOpportunityTreeNode::NGLayoutOpportunityTreeNode(
20 const NGLogicalRect opportunity, 20 const NGLogicalRect opportunity,
21 NGEdge exclusion_edge) 21 NGEdge exclusion_edge)
22 : opportunity(opportunity), exclusion_edge(exclusion_edge) {} 22 : opportunity(opportunity),
23 exclusion_edge(exclusion_edge),
24 exclusion(nullptr) {}
23 25
24 DEFINE_TRACE(NGLayoutOpportunityTreeNode) { 26 DEFINE_TRACE(NGLayoutOpportunityTreeNode) {
25 visitor->trace(left); 27 visitor->trace(left);
26 visitor->trace(bottom); 28 visitor->trace(bottom);
27 visitor->trace(right); 29 visitor->trace(right);
28 visitor->trace(exclusion);
29 } 30 }
30 31
31 } // namespace blink 32 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698