From 5b05aa7c5262c6f1a2b9741eab837ad6dd21c7e7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emilio=20Cobos=20=C3=81lvarez?= Date: Sat, 9 Sep 2017 13:25:53 +0200 Subject: [PATCH] style: Derive ToComputedValue in grid properties. --- components/style/properties/longhand/position.mako.rs | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/components/style/properties/longhand/position.mako.rs b/components/style/properties/longhand/position.mako.rs index e1cd423a689..ff163346238 100644 --- a/components/style/properties/longhand/position.mako.rs +++ b/components/style/properties/longhand/position.mako.rs @@ -291,19 +291,18 @@ ${helpers.predefined_type("object-position", animation_value_type="discrete"> use std::fmt; use style_traits::ToCss; - use values::computed::ComputedValueAsSpecified; pub type SpecifiedValue = computed_value::T; pub mod computed_value { - #[derive(Clone, Copy, Debug, Eq, PartialEq)] + #[derive(Clone, Copy, Debug, Eq, PartialEq, ToComputedValue)] #[cfg_attr(feature = "servo", derive(HeapSizeOf))] pub enum AutoFlow { Row, Column, } - #[derive(Clone, Copy, Debug, Eq, PartialEq)] + #[derive(Clone, Copy, Debug, Eq, PartialEq, ToComputedValue)] #[cfg_attr(feature = "servo", derive(HeapSizeOf))] pub struct T { pub autoflow: AutoFlow, @@ -311,8 +310,6 @@ ${helpers.predefined_type("object-position", } } - impl ComputedValueAsSpecified for SpecifiedValue {} - impl ToCss for computed_value::T { fn to_css(&self, dest: &mut W) -> fmt::Result where W: fmt::Write { dest.write_str(match self.autoflow {