mirror of
https://github.com/servo/servo.git
synced 2025-08-12 00:45:33 +01:00
rustify if statements style
This commit is contained in:
parent
3497bbbf1d
commit
729b8120e0
1 changed files with 13 additions and 5 deletions
|
@ -164,11 +164,19 @@ ${helpers.single_keyword("image-rendering",
|
||||||
// match Gecko's behavior when it was correct.
|
// match Gecko's behavior when it was correct.
|
||||||
rounded_angle = rounded_angle + TWO_PI;
|
rounded_angle = rounded_angle + TWO_PI;
|
||||||
}
|
}
|
||||||
if rounded_angle < 0.25 * PI { Orientation::Angle0 }
|
if rounded_angle < 0.25 * PI {
|
||||||
else if rounded_angle < 0.75 * PI { Orientation::Angle90 }
|
return Orientation::Angle0
|
||||||
else if rounded_angle < 1.25 * PI { Orientation::Angle180 }
|
}
|
||||||
else if rounded_angle < 1.75 * PI { Orientation::Angle270 }
|
if rounded_angle < 0.75 * PI {
|
||||||
else { Orientation::Angle0 }
|
return Orientation::Angle90
|
||||||
|
}
|
||||||
|
if rounded_angle < 1.25 * PI {
|
||||||
|
return Orientation::Angle180
|
||||||
|
}
|
||||||
|
if rounded_angle < 1.75 * PI {
|
||||||
|
return Orientation::Angle270
|
||||||
|
}
|
||||||
|
Orientation::Angle0
|
||||||
}
|
}
|
||||||
|
|
||||||
impl ToComputedValue for SpecifiedValue {
|
impl ToComputedValue for SpecifiedValue {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue