mirror of
https://github.com/servo/servo.git
synced 2025-08-14 01:45:33 +01:00
animations: Don't always re-resolve the node style
When animations and transitions change don't always re-resolve node style, just replace the animation and transition rules and re-cascade.
This commit is contained in:
parent
364235ac0c
commit
af0bb1f728
4 changed files with 108 additions and 108 deletions
|
@ -882,10 +882,9 @@ impl ElementAnimationSet {
|
|||
}
|
||||
|
||||
fn cancel_active_transitions(&mut self) {
|
||||
self.dirty = !self.transitions.is_empty();
|
||||
|
||||
for transition in self.transitions.iter_mut() {
|
||||
if transition.state != AnimationState::Finished {
|
||||
self.dirty = true;
|
||||
transition.state = AnimationState::Canceled;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue