mirror of
https://github.com/servo/servo.git
synced 2025-08-15 18:35:33 +01:00
Share a single #[animation(no_bound(…))] for the animation traits
This commit is contained in:
parent
ba12a344c6
commit
dcae5860a8
5 changed files with 22 additions and 24 deletions
|
@ -43,7 +43,7 @@ pub enum ShapeBox {
|
|||
|
||||
/// A shape source, for some reference box.
|
||||
#[allow(missing_docs)]
|
||||
#[animate(no_bound(ImageOrUrl))]
|
||||
#[animation(no_bound(ImageOrUrl))]
|
||||
#[derive(Animate, Clone, Debug, MallocSizeOf, PartialEq, ToComputedValue, ToCss)]
|
||||
pub enum ShapeSource<BasicShape, ReferenceBox, ImageOrUrl> {
|
||||
#[animation(error)]
|
||||
|
|
|
@ -15,10 +15,9 @@ use values::distance::{ComputeSquaredDistance, SquaredDistance};
|
|||
/// An SVG paint value
|
||||
///
|
||||
/// <https://www.w3.org/TR/SVG2/painting.html#SpecifyingPaint>
|
||||
#[animate(no_bound(UrlPaintServer))]
|
||||
#[animation(no_bound(UrlPaintServer))]
|
||||
#[derive(Animate, Clone, ComputeSquaredDistance, Debug, MallocSizeOf, PartialEq)]
|
||||
#[derive(ToAnimatedValue, ToComputedValue, ToCss)]
|
||||
#[distance(no_bound(UrlPaintServer))]
|
||||
pub struct SVGPaint<ColorType, UrlPaintServer> {
|
||||
/// The paint source
|
||||
pub kind: SVGPaintKind<ColorType, UrlPaintServer>,
|
||||
|
@ -31,11 +30,9 @@ pub struct SVGPaint<ColorType, UrlPaintServer> {
|
|||
/// Whereas the spec only allows PaintServer
|
||||
/// to have a fallback, Gecko lets the context
|
||||
/// properties have a fallback as well.
|
||||
#[animate(no_bound(UrlPaintServer))]
|
||||
#[animation(no_bound(UrlPaintServer))]
|
||||
#[derive(Animate, Clone, ComputeSquaredDistance, Debug, MallocSizeOf, PartialEq)]
|
||||
#[derive(ToAnimatedValue, ToAnimatedZero, ToComputedValue, ToCss)]
|
||||
#[distance(no_bound(UrlPaintServer))]
|
||||
#[zero(no_bound(UrlPaintServer))]
|
||||
pub enum SVGPaintKind<ColorType, UrlPaintServer> {
|
||||
/// `none`
|
||||
#[animation(error)]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue