Commit 05fdfeee authored by Manuel Rego Casasnovas's avatar Manuel Rego Casasnovas Committed by Commit Bot

Small change in NGOutOfFlowLayoutPart::Layout()

The method was getting the |container_content_size| as argument,
but it was only used to compute the |container_physical_content_size|.
The callers have already computed the |container_physical_content_size|
before calling this method, so we can simply pass it
and avoid recomputing it here.

BUG=1098231

Change-Id: I254256dd67123094086f3caa523735893a7b754e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2529163
Commit-Queue: Koji Ishii <kojii@chromium.org>
Reviewed-by: default avatarKoji Ishii <kojii@chromium.org>
Cr-Commit-Position: refs/heads/master@{#825886}
parent b47eca20
......@@ -601,7 +601,7 @@ scoped_refptr<const NGLayoutResult> NGOutOfFlowLayoutPart::LayoutCandidate(
do {
scoped_refptr<const NGLayoutResult> layout_result =
Layout(node, candidate_constraint_space, candidate_static_position,
container_content_size, container_info,
container_physical_content_size, container_info,
default_writing_direction, only_layout);
if (!freeze_scrollbars.has_value()) {
......@@ -703,8 +703,8 @@ void NGOutOfFlowLayoutPart::LayoutFragmentainerDescendant(
NGConstraintSpace descendant_constraint_space = builder.ToConstraintSpace();
Layout(node, descendant_constraint_space, descendant_static_position,
container_content_size, container_info, default_writing_direction,
/* only_layout */ nullptr,
container_physical_content_size, container_info,
default_writing_direction, /* only_layout */ nullptr,
/* is_fragmentainer_descendant */ true);
}
......@@ -712,7 +712,7 @@ scoped_refptr<const NGLayoutResult> NGOutOfFlowLayoutPart::Layout(
NGBlockNode node,
const NGConstraintSpace& candidate_constraint_space,
const NGLogicalStaticPosition& candidate_static_position,
LogicalSize container_content_size,
PhysicalSize container_physical_content_size,
const ContainingBlockInfo& container_info,
const WritingDirectionMode default_writing_direction,
const LayoutBox* only_layout,
......@@ -722,8 +722,6 @@ scoped_refptr<const NGLayoutResult> NGOutOfFlowLayoutPart::Layout(
candidate_style.GetWritingDirection();
const auto container_writing_direction = container_info.writing_direction;
PhysicalSize container_physical_content_size = ToPhysicalSize(
container_content_size, default_writing_direction.GetWritingMode());
LogicalSize container_content_size_in_candidate_writing_mode =
container_physical_content_size.ConvertToLogical(
candidate_writing_direction.GetWritingMode());
......
......@@ -120,7 +120,7 @@ class CORE_EXPORT NGOutOfFlowLayoutPart {
NGBlockNode,
const NGConstraintSpace&,
const NGLogicalStaticPosition&,
LogicalSize container_content_size,
PhysicalSize container_physical_content_size,
const ContainingBlockInfo&,
const WritingDirectionMode,
const LayoutBox* only_layout,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment