mirror of
https://github.com/servo/servo.git
synced 2025-08-03 20:50:07 +01:00
Auto merge of #20843 - emilio:font-stretch-anim, r=emilio
style: Fix font-stretch animation. This is a regression from #20506 which Gecko tests caught while trying to import this.
This commit is contained in:
commit
319556cf6a
1 changed files with 3 additions and 3 deletions
|
@ -21,7 +21,7 @@ use std::slice;
|
||||||
use style_traits::{CssWriter, ParseError, ToCss};
|
use style_traits::{CssWriter, ParseError, ToCss};
|
||||||
use values::CSSFloat;
|
use values::CSSFloat;
|
||||||
use values::animated::{ToAnimatedValue, ToAnimatedZero};
|
use values::animated::{ToAnimatedValue, ToAnimatedZero};
|
||||||
use values::computed::{Angle, Context, Integer, NonNegative, NonNegativeLength, NonNegativePercentage};
|
use values::computed::{Angle, Context, Integer, NonNegativeLength, NonNegativePercentage};
|
||||||
use values::computed::{Number, Percentage, ToComputedValue};
|
use values::computed::{Number, Percentage, ToComputedValue};
|
||||||
use values::generics::font::{self as generics, FeatureTagValue, FontSettings, VariationValue};
|
use values::generics::font::{self as generics, FeatureTagValue, FontSettings, VariationValue};
|
||||||
use values::specified::font::{self as specified, MIN_FONT_WEIGHT, MAX_FONT_WEIGHT};
|
use values::specified::font::{self as specified, MIN_FONT_WEIGHT, MAX_FONT_WEIGHT};
|
||||||
|
@ -953,12 +953,12 @@ impl ToAnimatedValue for FontStretch {
|
||||||
|
|
||||||
#[inline]
|
#[inline]
|
||||||
fn to_animated_value(self) -> Self::AnimatedValue {
|
fn to_animated_value(self) -> Self::AnimatedValue {
|
||||||
(self.0).0
|
self.0.to_animated_value()
|
||||||
}
|
}
|
||||||
|
|
||||||
#[inline]
|
#[inline]
|
||||||
fn from_animated_value(animated: Self::AnimatedValue) -> Self {
|
fn from_animated_value(animated: Self::AnimatedValue) -> Self {
|
||||||
FontStretch(NonNegative(animated))
|
FontStretch(NonNegativePercentage::from_animated_value(animated))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue