style: Add writing mode dependency if special MozLength keywords are used.

This commit is contained in:
Cameron McCormack 2017-09-13 16:06:48 +08:00
parent b3ee1c79c0
commit 1346be59b2

View file

@ -862,6 +862,10 @@ impl ToComputedValue for specified::MozLength {
MozLength::LengthOrPercentageOrAuto(lopoa.to_computed_value(context)) MozLength::LengthOrPercentageOrAuto(lopoa.to_computed_value(context))
} }
specified::MozLength::ExtremumLength(ref ext) => { specified::MozLength::ExtremumLength(ref ext) => {
debug_assert!(context.for_non_inherited_property.is_some(),
"should check whether we're a non-inherited property");
context.rule_cache_conditions.borrow_mut()
.set_writing_mode_dependency(context.builder.writing_mode);
MozLength::ExtremumLength(ext.clone()) MozLength::ExtremumLength(ext.clone())
} }
} }