aboutsummaryrefslogtreecommitdiffstats
path: root/components/layout/flow.rs
diff options
context:
space:
mode:
Diffstat (limited to 'components/layout/flow.rs')
-rw-r--r--components/layout/flow.rs17
1 files changed, 8 insertions, 9 deletions
diff --git a/components/layout/flow.rs b/components/layout/flow.rs
index 2d6e449766e..9ddfb274757 100644
--- a/components/layout/flow.rs
+++ b/components/layout/flow.rs
@@ -64,7 +64,6 @@ use style::logical_geometry::{LogicalRect, LogicalSize, WritingMode};
use style::properties::ComputedValues;
use style::selector_parser::RestyleDamage;
use style::servo::restyle_damage::ServoRestyleDamage;
-use style::values::computed::LengthPercentageOrAuto;
use webrender_api::units::LayoutTransform;
/// This marker trait indicates that a type is a struct with `#[repr(C)]` whose first field
@@ -1020,13 +1019,13 @@ impl BaseFlow {
flags.insert(FlowFlags::IS_ABSOLUTELY_POSITIONED);
let logical_position = style.logical_position();
- if logical_position.inline_start == LengthPercentageOrAuto::Auto &&
- logical_position.inline_end == LengthPercentageOrAuto::Auto
+ if logical_position.inline_start.is_auto() &&
+ logical_position.inline_end.is_auto()
{
flags.insert(FlowFlags::INLINE_POSITION_IS_STATIC);
}
- if logical_position.block_start == LengthPercentageOrAuto::Auto &&
- logical_position.block_end == LengthPercentageOrAuto::Auto
+ if logical_position.block_start.is_auto() &&
+ logical_position.block_end.is_auto()
{
flags.insert(FlowFlags::BLOCK_POSITION_IS_STATIC);
}
@@ -1113,13 +1112,13 @@ impl BaseFlow {
let logical_position = style.logical_position();
self.flags.set(
FlowFlags::INLINE_POSITION_IS_STATIC,
- logical_position.inline_start == LengthPercentageOrAuto::Auto &&
- logical_position.inline_end == LengthPercentageOrAuto::Auto,
+ logical_position.inline_start.is_auto() &&
+ logical_position.inline_end.is_auto()
);
self.flags.set(
FlowFlags::BLOCK_POSITION_IS_STATIC,
- logical_position.block_start == LengthPercentageOrAuto::Auto &&
- logical_position.block_end == LengthPercentageOrAuto::Auto,
+ logical_position.block_start.is_auto() &&
+ logical_position.block_end.is_auto()
);
}
}