mirror of
https://github.com/servo/servo.git
synced 2025-08-03 20:50:07 +01:00
Add has_current_styles_for_traversal().
In animation-only restyle, we just need to check the element has animation restyle hints or has recascade self which is a result of animation-only restyle for ancestors. has_current_styles() in Servo_ResolveStyle() is intentionally left there, it will be changed in a subsequent patch.
This commit is contained in:
parent
ae55e51aaf
commit
f91126ba86
4 changed files with 37 additions and 7 deletions
|
@ -131,6 +131,13 @@ impl RestyleHint {
|
|||
self.intersects(Self::for_animations())
|
||||
}
|
||||
|
||||
/// Returns whether the hint specifies that an animation cascade level must
|
||||
/// be replaced.
|
||||
#[inline]
|
||||
pub fn has_animation_hint_or_recascade(&self) -> bool {
|
||||
self.intersects(Self::for_animations() | RECASCADE_SELF)
|
||||
}
|
||||
|
||||
/// Returns whether the hint specifies some restyle work other than an
|
||||
/// animation cascade level replacement.
|
||||
#[inline]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue