| OLD | NEW |
| 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_constraint_space.h" | 5 #include "core/layout/ng/ng_constraint_space.h" |
| 6 | 6 |
| 7 #include "core/layout/LayoutBlock.h" | 7 #include "core/layout/LayoutBlock.h" |
| 8 #include "core/layout/LayoutView.h" | 8 #include "core/layout/LayoutView.h" |
| 9 #include "core/layout/ng/ng_constraint_space_builder.h" | 9 #include "core/layout/ng/ng_constraint_space_builder.h" |
| 10 #include "core/layout/ng/ng_layout_opportunity_iterator.h" | 10 #include "core/layout/ng/ng_layout_opportunity_iterator.h" |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 44 block_direction_fragmentation_type_(block_direction_fragmentation_type), | 44 block_direction_fragmentation_type_(block_direction_fragmentation_type), |
| 45 is_new_fc_(is_new_fc), | 45 is_new_fc_(is_new_fc), |
| 46 is_anonymous_(is_anonymous), | 46 is_anonymous_(is_anonymous), |
| 47 writing_mode_(writing_mode), | 47 writing_mode_(writing_mode), |
| 48 direction_(static_cast<unsigned>(direction)), | 48 direction_(static_cast<unsigned>(direction)), |
| 49 margin_strut_(margin_strut), | 49 margin_strut_(margin_strut), |
| 50 bfc_offset_(bfc_offset), | 50 bfc_offset_(bfc_offset), |
| 51 exclusions_(exclusions), | 51 exclusions_(exclusions), |
| 52 clearance_offset_(clearance_offset) {} | 52 clearance_offset_(clearance_offset) {} |
| 53 | 53 |
| 54 NGConstraintSpace* NGConstraintSpace::CreateFromLayoutObject( | 54 RefPtr<NGConstraintSpace> NGConstraintSpace::CreateFromLayoutObject( |
| 55 const LayoutBox& box) { | 55 const LayoutBox& box) { |
| 56 auto writing_mode = FromPlatformWritingMode(box.styleRef().getWritingMode()); | 56 auto writing_mode = FromPlatformWritingMode(box.styleRef().getWritingMode()); |
| 57 bool parallel_containing_block = IsParallelWritingMode( | 57 bool parallel_containing_block = IsParallelWritingMode( |
| 58 FromPlatformWritingMode( | 58 FromPlatformWritingMode( |
| 59 box.containingBlock()->styleRef().getWritingMode()), | 59 box.containingBlock()->styleRef().getWritingMode()), |
| 60 writing_mode); | 60 writing_mode); |
| 61 bool fixed_inline = false, fixed_block = false; | 61 bool fixed_inline = false, fixed_block = false; |
| 62 | 62 |
| 63 LayoutUnit available_logical_width; | 63 LayoutUnit available_logical_width; |
| 64 if (parallel_containing_block) | 64 if (parallel_containing_block) |
| (...skipping 79 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 144 bfc_offset_.block_offset.toString().ascii().data(), | 144 bfc_offset_.block_offset.toString().ascii().data(), |
| 145 AvailableSize().inline_size.toString().ascii().data(), | 145 AvailableSize().inline_size.toString().ascii().data(), |
| 146 AvailableSize().block_size.toString().ascii().data(), | 146 AvailableSize().block_size.toString().ascii().data(), |
| 147 margin_strut_.ToString().ascii().data(), | 147 margin_strut_.ToString().ascii().data(), |
| 148 clearance_offset_.has_value() | 148 clearance_offset_.has_value() |
| 149 ? clearance_offset_.value().toString().ascii().data() | 149 ? clearance_offset_.value().toString().ascii().data() |
| 150 : "none"); | 150 : "none"); |
| 151 } | 151 } |
| 152 | 152 |
| 153 } // namespace blink | 153 } // namespace blink |
| OLD | NEW |