Use Python's True instead of string for arbitrary Python code in mako

This commit is contained in:
CYBAI 2018-01-13 00:14:53 +08:00 committed by Bobby Holley
parent 75f39b42ab
commit a061f2a89f
7 changed files with 12 additions and 12 deletions

View file

@ -210,7 +210,7 @@ ${helpers.predefined_type("border-image-source", "ImageLayer",
vector=False,
animation_value_type="discrete",
flags="APPLIES_TO_FIRST_LETTER",
boxed="True")}
boxed=True)}
${helpers.predefined_type("border-image-outset", "LengthOrNumberRect",
parse_method="parse_non_negative",

View file

@ -389,7 +389,7 @@ ${helpers.predefined_type("scroll-snap-destination",
"computed::Position::zero()",
products="gecko",
gecko_pref="layout.css.scroll-snap.enabled",
boxed="True",
boxed=True,
spec="Nonstandard (https://developer.mozilla.org/en-US/docs/Web/CSS/scroll-snap-destination)",
animation_value_type="discrete")}
@ -505,7 +505,7 @@ ${helpers.predefined_type("perspective",
${helpers.predefined_type("perspective-origin",
"position::Position",
"computed::position::Position::center()",
boxed="True",
boxed=True,
extra_prefixes="moz webkit",
spec="https://drafts.csswg.org/css-transforms-2/#perspective-origin-property",
animation_value_type="ComputedValue")}
@ -589,7 +589,7 @@ ${helpers.single_keyword("-moz-appearance",
${helpers.predefined_type("-moz-binding", "UrlOrNone", "Either::Second(None_)",
products="gecko",
boxed="True" if product == "gecko" else "False",
boxed= product == "gecko",
animation_value_type="none",
gecko_ffi_name="mBinding",
spec="Nonstandard (https://developer.mozilla.org/en-US/docs/Web/CSS/-moz-binding)")}

View file

@ -30,7 +30,7 @@ ${helpers.predefined_type("clip",
"ClipRectOrAuto",
"computed::ClipRectOrAuto::auto()",
animation_value_type="ComputedValue",
boxed="True",
boxed=True,
allow_quirks=True,
spec="https://drafts.fxtf.org/css-masking/#clip-property")}

View file

@ -114,19 +114,19 @@ ${helpers.single_keyword("clip-rule", "nonzero evenodd",
${helpers.predefined_type("marker-start", "UrlOrNone", "Either::Second(None_)",
products="gecko",
boxed="True" if product == "gecko" else "False",
boxed= product == "gecko",
animation_value_type="discrete",
spec="https://www.w3.org/TR/SVG2/painting.html#VertexMarkerProperties")}
${helpers.predefined_type("marker-mid", "UrlOrNone", "Either::Second(None_)",
products="gecko",
boxed="True" if product == "gecko" else "False",
boxed= product == "gecko",
animation_value_type="discrete",
spec="https://www.w3.org/TR/SVG2/painting.html#VertexMarkerProperties")}
${helpers.predefined_type("marker-end", "UrlOrNone", "Either::Second(None_)",
products="gecko",
boxed="True" if product == "gecko" else "False",
boxed= product == "gecko",
animation_value_type="discrete",
spec="https://www.w3.org/TR/SVG2/painting.html#VertexMarkerProperties")}

View file

@ -24,5 +24,5 @@ ${helpers.predefined_type("border-spacing",
"BorderSpacing",
"computed::BorderSpacing::zero()",
animation_value_type="BorderSpacing",
boxed="True",
boxed=True,
spec="https://drafts.csswg.org/css-tables/#propdef-border-spacing")}

View file

@ -35,7 +35,7 @@ ${helpers.single_keyword("list-style-position", "outside inside", animation_valu
"computed::ListStyleType::disc()",
initial_specified_value="specified::ListStyleType::disc()",
animation_value_type="discrete",
boxed="True",
boxed=True,
spec="https://drafts.csswg.org/css-lists/#propdef-list-style-type")}
% endif
@ -58,5 +58,5 @@ ${helpers.predefined_type("-moz-image-region",
"computed::ClipRectOrAuto::auto()",
animation_value_type="ComputedValue",
products="gecko",
boxed="True",
boxed=True,
spec="Nonstandard (https://developer.mozilla.org/en-US/docs/Web/CSS/-moz-image-region)")}

View file

@ -247,7 +247,7 @@ ${helpers.predefined_type("object-position",
"Position",
"computed::Position::zero()",
products="gecko",
boxed="True",
boxed=True,
spec="https://drafts.csswg.org/css-images-3/#the-object-position",
animation_value_type="ComputedValue")}