mirror of
https://github.com/servo/servo.git
synced 2025-08-07 06:25:32 +01:00
Allow cross interpolation between differing translate/scale functions
See ToPrimitive() in StyleAnimationValue.cpp
This commit is contained in:
parent
f699b8cfb2
commit
9c9a181f35
4 changed files with 12 additions and 3 deletions
|
@ -1226,7 +1226,12 @@ impl Animate for ComputedTransformOperation {
|
|||
fd_matrix.animate(&td_matrix, procedure)?,
|
||||
))
|
||||
},
|
||||
// XXXManishearth handle crossover between translate and scale functions
|
||||
(ref f, ref t) if f.is_translate() && t.is_translate() => {
|
||||
f.to_translate_3d().animate(&t.to_translate_3d(), procedure)
|
||||
}
|
||||
(ref f, ref t) if f.is_scale() && t.is_scale() => {
|
||||
f.to_scale_3d().animate(&t.to_scale_3d(), procedure)
|
||||
}
|
||||
_ => Err(()),
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue