Don't use define_css_keyword_enum in style anymore

This commit is contained in:
Anthony Ramine 2018-01-30 13:52:11 +01:00
parent 09e304adb3
commit 3d99a4489c
14 changed files with 174 additions and 158 deletions

View file

@ -97,15 +97,18 @@ pub enum Ellipse<LengthOrPercentage> {
}
/// <https://drafts.csswg.org/css-images/#typedef-extent-keyword>
define_css_keyword_enum!(ShapeExtent:
"closest-side" => ClosestSide,
"farthest-side" => FarthestSide,
"closest-corner" => ClosestCorner,
"farthest-corner" => FarthestCorner,
"contain" => Contain,
"cover" => Cover
);
add_impls_for_keyword_enum!(ShapeExtent);
#[allow(missing_docs)]
#[cfg_attr(feature = "servo", derive(Deserialize, Serialize))]
#[derive(Clone, Copy, Debug, Eq, MallocSizeOf, Parse, PartialEq)]
#[derive(ToComputedValue, ToCss)]
pub enum ShapeExtent {
ClosestSide,
FarthestSide,
ClosestCorner,
FarthestCorner,
Contain,
Cover,
}
/// A gradient item.
/// <https://drafts.csswg.org/css-images-4/#color-stop-syntax>