From c483f078cc51e446e1ab7aaef3217993e58abfe9 Mon Sep 17 00:00:00 2001 From: Stefano Chiodino Date: Tue, 14 Mar 2017 10:30:30 +0000 Subject: [PATCH] Add set and copy functions for caret_color --- components/style/properties/gecko.mako.rs | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/components/style/properties/gecko.mako.rs b/components/style/properties/gecko.mako.rs index 8e52d9d739c..4d7e49f39e9 100644 --- a/components/style/properties/gecko.mako.rs +++ b/components/style/properties/gecko.mako.rs @@ -3096,7 +3096,7 @@ clip-path <%self:impl_trait style_struct_name="Pointing" - skip_longhands="cursor"> + skip_longhands="cursor caret-color"> pub fn set_cursor(&mut self, v: longhands::cursor::computed_value::T) { use properties::longhands::cursor::computed_value::Keyword; use style_traits::cursor::Cursor; @@ -3171,6 +3171,23 @@ clip-path Gecko_CopyCursorArrayFrom(&mut self.gecko, &other.gecko); } } + + pub fn set_caret_color(&mut self, v: longhands::caret_color::computed_value::T){ + use values::Either; + + match v { + Either::First(color) => { + self.gecko.mCaretColor = color; + } + Either::Second(_auto) => { + self.gecko.mCaretColor.auto(); + } + } + } + + pub fn copy_caret_color_from(&mut self, other: &Self){ + self.gecko.mCaretColor = other.gecko.mCaretColor; + } <%self:impl_trait style_struct_name="Column"