Commit 6b591b59 authored by Koji Ishii's avatar Koji Ishii Committed by Commit Bot

[LayoutNG] Cleanup unused variable in NGBlockNode

This patch cleans up an unused variable I happened to find
while debugging.

Bug: 591099
Cq-Include-Trybots: master.tryserver.chromium.linux:linux_layout_tests_layout_ng
Change-Id: I4498954e510e0a64362b688fe20ea46014906f0e
Reviewed-on: https://chromium-review.googlesource.com/958649Reviewed-by: default avatarMorten Stenshorne <mstensho@chromium.org>
Commit-Queue: Koji Ishii <kojii@chromium.org>
Cr-Commit-Position: refs/heads/master@{#542718}
parent b0c0f4ac
...@@ -312,6 +312,7 @@ void NGBlockNode::CopyFragmentDataToLayoutBox( ...@@ -312,6 +312,7 @@ void NGBlockNode::CopyFragmentDataToLayoutBox(
ToNGPhysicalBoxFragment(*layout_result.PhysicalFragment()); ToNGPhysicalBoxFragment(*layout_result.PhysicalFragment());
NGBoxFragment fragment(constraint_space.GetWritingMode(), physical_fragment); NGBoxFragment fragment(constraint_space.GetWritingMode(), physical_fragment);
NGLogicalSize fragment_logical_size = fragment.Size();
// For each fragment we process, we'll accumulate the logical height and // For each fragment we process, we'll accumulate the logical height and
// logical intrinsic content box height. We reset it at the first fragment, // logical intrinsic content box height. We reset it at the first fragment,
// and accumulate at each method call for fragments belonging to the same // and accumulate at each method call for fragments belonging to the same
...@@ -321,14 +322,14 @@ void NGBlockNode::CopyFragmentDataToLayoutBox( ...@@ -321,14 +322,14 @@ void NGBlockNode::CopyFragmentDataToLayoutBox(
LayoutUnit logical_height; LayoutUnit logical_height;
LayoutUnit intrinsic_content_logical_height; LayoutUnit intrinsic_content_logical_height;
if (IsFirstFragment(constraint_space, physical_fragment)) { if (IsFirstFragment(constraint_space, physical_fragment)) {
box_->SetLogicalWidth(fragment.InlineSize()); box_->SetLogicalWidth(fragment_logical_size.inline_size);
} else { } else {
DCHECK_EQ(box_->LogicalWidth(), fragment.InlineSize()) DCHECK_EQ(box_->LogicalWidth(), fragment_logical_size.inline_size)
<< "Variable fragment inline size not supported"; << "Variable fragment inline size not supported";
logical_height = box_->LogicalHeight(); logical_height = box_->LogicalHeight();
intrinsic_content_logical_height = box_->IntrinsicContentLogicalHeight(); intrinsic_content_logical_height = box_->IntrinsicContentLogicalHeight();
} }
logical_height += fragment.BlockSize(); logical_height += fragment_logical_size.block_size;
intrinsic_content_logical_height += layout_result.IntrinsicBlockSize(); intrinsic_content_logical_height += layout_result.IntrinsicBlockSize();
NGBoxStrut border_scrollbar_padding = NGBoxStrut border_scrollbar_padding =
ComputeBorders(constraint_space, Style()) + ComputeBorders(constraint_space, Style()) +
...@@ -361,8 +362,6 @@ void NGBlockNode::CopyFragmentDataToLayoutBox( ...@@ -361,8 +362,6 @@ void NGBlockNode::CopyFragmentDataToLayoutBox(
if (box_->IsLayoutBlock() && IsLastFragment(physical_fragment)) { if (box_->IsLayoutBlock() && IsLastFragment(physical_fragment)) {
LayoutBlock* block = ToLayoutBlock(box_); LayoutBlock* block = ToLayoutBlock(box_);
WritingMode writing_mode = constraint_space.GetWritingMode();
NGBoxFragment fragment(writing_mode, physical_fragment);
LayoutUnit intrinsic_block_size = layout_result.IntrinsicBlockSize(); LayoutUnit intrinsic_block_size = layout_result.IntrinsicBlockSize();
if (constraint_space.HasBlockFragmentation()) { if (constraint_space.HasBlockFragmentation()) {
intrinsic_block_size += intrinsic_block_size +=
......
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