style: Conversion from NS_STYLE_BORDER_STYLE_* macro to enum class.

Converted NS_STYLE_BORDER_STYLE_* consts to enum class. Updated corresponding
values to enum class. reduced BCCornerInfo struct values to fit StyleBorderStyle
values inside struct. Added defaults to switches that do not fully cover all
instances of StyleBorderStyle.

Bug: 1460439
Reviewed-by: emilio
This commit is contained in:
Kristen Wright 2018-11-07 11:56:17 -08:00 committed by Emilio Cobos Álvarez
parent d404a0cddd
commit 149815ab3b
3 changed files with 8 additions and 3 deletions

View file

@ -1516,7 +1516,9 @@ fn static_assert() {
<% border_style_keyword = Keyword("border-style",
"none solid double dotted dashed hidden groove ridge inset outset") %>
"none solid double dotted dashed hidden groove ridge inset outset",
gecko_enum_prefix="StyleBorderStyle",
gecko_inexhaustive=True) %>
<% skip_border_longhands = " ".join(["border-{0}-{1}".format(x.ident, y)
for x in SIDES

View file

@ -63,7 +63,9 @@
${helpers.gecko_keyword_conversion(
Keyword('border-style',
"none solid double dotted dashed hidden groove ridge inset outset"),
"none solid double dotted dashed hidden groove ridge inset outset",
gecko_enum_prefix="StyleBorderStyle",
gecko_inexhaustive=True),
type="crate::values::specified::BorderStyle",
)}

View file

@ -83,7 +83,8 @@ ${helpers.single_keyword(
"none hidden dotted dashed solid double groove ridge inset outset",
products="gecko",
extra_prefixes="moz",
gecko_constant_prefix="NS_STYLE_BORDER_STYLE",
gecko_enum_prefix="StyleBorderStyle",
gecko_inexhaustive=True,
animation_value_type="discrete",
spec="https://drafts.csswg.org/css-multicol/#propdef-column-rule-style",
)}