Support {background,outline}-color in geckolib.

This commit is contained in:
Cameron McCormack 2016-05-02 14:43:46 +10:00
parent 330c47f78e
commit d8969e2447

View file

@ -476,11 +476,13 @@ fn static_assert() {
</%self:impl_trait>
<%self:impl_trait style_struct_name="Outline"
skip_longhands="outline-style"
skip_longhands="outline-color outline-style"
skip_additionals="*">
<% impl_keyword("outline_style", "mOutlineStyle", border_style_keyword, need_clone=True) %>
<% impl_color("outline_color", "mOutlineColor", color_flags_ffi_name="mOutlineStyle") %>
fn outline_has_nonzero_width(&self) -> bool {
self.gecko.mCachedOutlineWidth != 0
}
@ -546,6 +548,12 @@ fn static_assert() {
</%self:impl_trait>
<%self:impl_trait style_struct_name="Background" skip_longhands="background-color" skip_additionals="*">
<% impl_color("background_color", "mBackgroundColor") %>
</%self:impl_trait>
<%self:impl_trait style_struct_name="Text"
skip_longhands="text-decoration-color"
skip_additionals="*">