mirror of
https://github.com/servo/servo.git
synced 2025-08-07 06:25:32 +01:00
style: Return Err() in to_animated_zero() for offset-path
It's unnecessary to implement ToAnimatedZero for this property and so we return Err(()), just like other properties which also use basic shapes, e.g. clip-path, shape-outside. Differential Revision: https://phabricator.services.mozilla.com/D179859
This commit is contained in:
parent
52e2cc5ff0
commit
8b60424e29
1 changed files with 8 additions and 3 deletions
|
@ -4,6 +4,7 @@
|
||||||
|
|
||||||
//! Generic types for CSS Motion Path.
|
//! Generic types for CSS Motion Path.
|
||||||
|
|
||||||
|
use crate::values::animated::ToAnimatedZero;
|
||||||
use crate::values::generics::position::GenericPosition;
|
use crate::values::generics::position::GenericPosition;
|
||||||
use crate::values::specified::SVGPathData;
|
use crate::values::specified::SVGPathData;
|
||||||
|
|
||||||
|
@ -21,7 +22,6 @@ use crate::values::specified::SVGPathData;
|
||||||
PartialEq,
|
PartialEq,
|
||||||
Serialize,
|
Serialize,
|
||||||
SpecifiedValueInfo,
|
SpecifiedValueInfo,
|
||||||
ToAnimatedZero,
|
|
||||||
ToComputedValue,
|
ToComputedValue,
|
||||||
ToCss,
|
ToCss,
|
||||||
ToResolvedValue,
|
ToResolvedValue,
|
||||||
|
@ -57,7 +57,6 @@ impl RaySize {
|
||||||
PartialEq,
|
PartialEq,
|
||||||
Serialize,
|
Serialize,
|
||||||
SpecifiedValueInfo,
|
SpecifiedValueInfo,
|
||||||
ToAnimatedZero,
|
|
||||||
ToComputedValue,
|
ToComputedValue,
|
||||||
ToCss,
|
ToCss,
|
||||||
ToResolvedValue,
|
ToResolvedValue,
|
||||||
|
@ -93,7 +92,6 @@ pub struct RayFunction<Angle> {
|
||||||
PartialEq,
|
PartialEq,
|
||||||
Serialize,
|
Serialize,
|
||||||
SpecifiedValueInfo,
|
SpecifiedValueInfo,
|
||||||
ToAnimatedZero,
|
|
||||||
ToComputedValue,
|
ToComputedValue,
|
||||||
ToCss,
|
ToCss,
|
||||||
ToResolvedValue,
|
ToResolvedValue,
|
||||||
|
@ -125,6 +123,13 @@ impl<Angle> OffsetPath<Angle> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
impl<Angle> ToAnimatedZero for OffsetPath<Angle> {
|
||||||
|
#[inline]
|
||||||
|
fn to_animated_zero(&self) -> Result<Self, ()> {
|
||||||
|
Err(())
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/// The offset-position property, which specifies the offset starting position that is used by the
|
/// The offset-position property, which specifies the offset starting position that is used by the
|
||||||
/// <offset-path> functions if they don’t specify their own starting position.
|
/// <offset-path> functions if they don’t specify their own starting position.
|
||||||
///
|
///
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue