mirror of
https://github.com/servo/servo.git
synced 2025-08-03 12:40:06 +01:00
Change AnimatedValue for GreaterThanOrEqualToOneNumber to CSSFloat
This commit is contained in:
parent
f89ebf7fe9
commit
056abcbf5f
4 changed files with 19 additions and 21 deletions
|
@ -15,7 +15,6 @@ use values::computed::Angle as ComputedAngle;
|
|||
use values::computed::BorderCornerRadius as ComputedBorderCornerRadius;
|
||||
#[cfg(feature = "servo")]
|
||||
use values::computed::ComputedUrl;
|
||||
use values::computed::GreaterThanOrEqualToOneNumber as ComputedGreaterThanOrEqualToOneNumber;
|
||||
use values::computed::MaxLength as ComputedMaxLength;
|
||||
use values::computed::MozLength as ComputedMozLength;
|
||||
use values::computed::NonNegativeLength as ComputedNonNegativeLength;
|
||||
|
@ -262,20 +261,6 @@ trivial_to_animated_value!(ComputedUrl);
|
|||
trivial_to_animated_value!(bool);
|
||||
trivial_to_animated_value!(f32);
|
||||
|
||||
impl ToAnimatedValue for ComputedGreaterThanOrEqualToOneNumber {
|
||||
type AnimatedValue = Self;
|
||||
|
||||
#[inline]
|
||||
fn to_animated_value(self) -> Self {
|
||||
self
|
||||
}
|
||||
|
||||
#[inline]
|
||||
fn from_animated_value(animated: Self::AnimatedValue) -> Self {
|
||||
animated.0.max(1.).into()
|
||||
}
|
||||
}
|
||||
|
||||
impl ToAnimatedValue for ComputedNonNegativeLength {
|
||||
type AnimatedValue = Self;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue