style: Unpack StyleMotion and use cbindgen for OffsetPath.

Unpack StyleMotion and move its members into nsStyleDisplay, use
cbindgen to generate StyleOffsetPath.

Differential Revision: https://phabricator.services.mozilla.com/D31164
This commit is contained in:
Boris Chiou 2019-05-20 23:42:50 +00:00 committed by Emilio Cobos Álvarez
parent 8ee516b681
commit d80a5d9196
2 changed files with 3 additions and 35 deletions

View file

@ -12,6 +12,7 @@ use style_traits::{ParseError, StyleParseErrorKind};
/// The offset-path value.
///
/// https://drafts.fxtf.org/motion-1/#offset-path-property
/// cbindgen:derive-tagged-enum-copy-constructor=true
#[derive(
Animate,
Clone,
@ -26,6 +27,7 @@ use style_traits::{ParseError, StyleParseErrorKind};
ToResolvedValue,
ToShmem,
)]
#[repr(C, u8)]
pub enum OffsetPath {
// We could merge SVGPathData into ShapeSource, so we could reuse them. However,
// we don't want to support other value for offset-path, so use SVGPathData only for now.