Get rid of some of our custom additional methods in favor of clonable keywords.

Now that I'm pretty convinced we can auto-generate these and make them fast, we can
ditch the additional complexity.
This commit is contained in:
Bobby Holley 2016-04-19 16:41:38 -07:00
parent 456b05e9cf
commit cc35d4fcce
5 changed files with 36 additions and 27 deletions

View file

@ -7,7 +7,7 @@
<% from data import Method %>
<% data.new_style_struct("Border", inherited=False, gecko_ffi_name="nsStyleBorder",
additional_methods=[Method("border_" + side + "_is_none_or_hidden_and_has_nonzero_width",
additional_methods=[Method("border_" + side + "_has_nonzero_width",
"bool") for side in ["top", "right", "bottom", "left"]]) %>
% for side in ["top", "right", "bottom", "left"]:
@ -15,7 +15,7 @@
% endfor
% for side in ["top", "right", "bottom", "left"]:
${helpers.predefined_type("border-%s-style" % side, "BorderStyle", "specified::BorderStyle::none")}
${helpers.predefined_type("border-%s-style" % side, "BorderStyle", "specified::BorderStyle::none", need_clone=True)}
% endfor
% for side in ["top", "right", "bottom", "left"]: