mirror of
https://github.com/servo/servo.git
synced 2025-08-07 06:25:32 +01:00
style: Add a Zero trait that doesn't require Add, and use it in place of num_traits and IsZeroLength.
Use it to be consistent in InsetRect serialization and storage between Servo and Gecko. Differential Revision: https://phabricator.services.mozilla.com/D21493
This commit is contained in:
parent
4496411edc
commit
7d01114cbf
29 changed files with 179 additions and 186 deletions
|
@ -4629,10 +4629,7 @@ fn set_style_svg_path(
|
|||
inset.rect.2.to_gecko_style_coord(&mut shape.mCoordinates[2]);
|
||||
shape.mCoordinates[3].leaky_set_null();
|
||||
inset.rect.3.to_gecko_style_coord(&mut shape.mCoordinates[3]);
|
||||
shape.mRadius = match inset.round {
|
||||
Some(radius) => radius,
|
||||
None => crate::values::computed::BorderRadius::zero(),
|
||||
};
|
||||
shape.mRadius = inset.round;
|
||||
}
|
||||
BasicShape::Circle(circ) => {
|
||||
let shape = init_shape(${ident}, StyleBasicShapeType::Circle);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue