diff options
author | bors-servo <lbergstrom+bors@mozilla.com> | 2019-12-16 23:51:18 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-12-16 23:51:18 -0500 |
commit | a8b8f4647622dc88e2d19c04de3948795dcc594d (patch) | |
tree | 50ccc190c83684029855eeaf1b0b422b90da062e /components/layout/flow.rs | |
parent | b274d59875522ad303e9b54c17414dd57dee325b (diff) | |
parent | 7513bc293e0e515dd4e9e56b8ede32b68b8c8186 (diff) | |
download | servo-a8b8f4647622dc88e2d19c04de3948795dcc594d.tar.gz servo-a8b8f4647622dc88e2d19c04de3948795dcc594d.zip |
Auto merge of #25299 - emilio:gecko-sync, r=emilio,nox
style: Sync changes from mozilla-central.
See individual commits for details.
Diffstat (limited to 'components/layout/flow.rs')
-rw-r--r-- | components/layout/flow.rs | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/components/layout/flow.rs b/components/layout/flow.rs index 2d6e449766e..c2d01b7f9f9 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,12 @@ 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(), ); } } |