mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
stylo: call update_border_foo when inheriting borders too
This commit is contained in:
parent
020188fdd7
commit
68d67ef3f5
1 changed files with 5 additions and 2 deletions
|
@ -378,10 +378,13 @@ impl ${style_struct.gecko_struct_name} {
|
|||
}
|
||||
</%def>
|
||||
|
||||
<%def name="impl_simple_copy(ident, gecko_ffi_name, *kwargs)">
|
||||
<%def name="impl_simple_copy(ident, gecko_ffi_name, on_set=None, *kwargs)">
|
||||
#[allow(non_snake_case)]
|
||||
pub fn copy_${ident}_from(&mut self, other: &Self) {
|
||||
self.gecko.${gecko_ffi_name} = other.gecko.${gecko_ffi_name};
|
||||
% if on_set:
|
||||
self.${on_set}();
|
||||
% endif
|
||||
}
|
||||
</%def>
|
||||
|
||||
|
@ -478,7 +481,7 @@ def set_gecko_property(ffi_name, expr):
|
|||
|
||||
<%def name="impl_keyword(ident, gecko_ffi_name, keyword, need_clone, cast_type='u8', **kwargs)">
|
||||
<%call expr="impl_keyword_setter(ident, gecko_ffi_name, keyword, cast_type, **kwargs)"></%call>
|
||||
<%call expr="impl_simple_copy(ident, gecko_ffi_name)"></%call>
|
||||
<%call expr="impl_simple_copy(ident, gecko_ffi_name, **kwargs)"></%call>
|
||||
%if need_clone:
|
||||
<%call expr="impl_keyword_clone(ident, gecko_ffi_name, keyword, cast_type)"></%call>
|
||||
% endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue