style: Animate offset-rotate.

Differential Revision: https://phabricator.services.mozilla.com/D32237
This commit is contained in:
Boris Chiou 2019-05-28 18:31:48 +00:00 committed by Emilio Cobos Álvarez
parent b34c27339b
commit 8a0cf600d6
2 changed files with 14 additions and 2 deletions

View file

@ -390,7 +390,7 @@ ${helpers.predefined_type(
"OffsetRotate",
"computed::OffsetRotate::auto()",
products="gecko",
animation_value_type="none",
animation_value_type="ComputedValue",
gecko_pref="layout.css.motion-path.enabled",
spec="https://drafts.fxtf.org/motion-1/#offset-rotate-property",
servo_restyle_damage="reflow_out_of_flow"

View file

@ -18,13 +18,25 @@ fn is_auto_zero_angle(auto: &bool, angle: &Angle) -> bool {
}
/// A computed offset-rotate.
#[derive(Clone, Copy, Debug, MallocSizeOf, PartialEq, ToCss, ToResolvedValue)]
#[derive(
Animate,
Clone,
ComputeSquaredDistance,
Copy,
Debug,
MallocSizeOf,
PartialEq,
ToAnimatedZero,
ToCss,
ToResolvedValue,
)]
#[repr(C)]
pub struct OffsetRotate {
/// If auto is false, this is a fixed angle which indicates a
/// constant clockwise rotation transformation applied to it by this
/// specified rotation angle. Otherwise, the angle will be added to
/// the angle of the direction in layout.
#[animation(constant)]
#[css(represents_keyword)]
pub auto: bool,
/// The angle value.