Pass SharedStyleContext to compute_used_inline_size.

This commit is contained in:
Ms2ger 2016-06-20 19:55:48 +02:00
parent 018bebe90d
commit 9731a001db
6 changed files with 25 additions and 20 deletions

View file

@ -25,6 +25,7 @@ use script_layout_interface::restyle_damage::{REFLOW, REFLOW_OUT_OF_FLOW};
use std::cmp::max;
use std::sync::Arc;
use style::computed_values::flex_direction;
use style::context::StyleContext;
use style::logical_geometry::LogicalSize;
use style::properties::{ComputedValues, ServoComputedValues};
use style::values::computed::{LengthOrPercentage, LengthOrPercentageOrAuto, LengthOrPercentageOrNone};
@ -413,7 +414,7 @@ impl Flow for FlexFlow {
// Our inline-size was set to the inline-size of the containing block by the flow's parent.
// Now compute the real value.
let containing_block_inline_size = self.block_flow.base.block_container_inline_size;
self.block_flow.compute_used_inline_size(layout_context, containing_block_inline_size);
self.block_flow.compute_used_inline_size(layout_context.shared_context(), containing_block_inline_size);
if self.block_flow.base.flags.is_float() {
self.block_flow.float.as_mut().unwrap().containing_inline_size = containing_block_inline_size
}