mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Bug 1341372 - Part 1: Let animation-only restyle include css-transition.
Animation-only restyle should include both Animation and Transition cascade levels. MozReview-Commit-ID: 5l6gaJKbixM
This commit is contained in:
parent
485a4de729
commit
1c1e487491
6 changed files with 77 additions and 24 deletions
|
@ -1788,12 +1788,15 @@ pub extern "C" fn Servo_NoteExplicitHints(element: RawGeckoElementBorrowed,
|
|||
debug!("Servo_NoteExplicitHints: {:?}, restyle_hint={:?}, change_hint={:?}",
|
||||
element, restyle_hint, change_hint);
|
||||
debug_assert!(restyle_hint == structs::nsRestyleHint_eRestyle_CSSAnimations ||
|
||||
(restyle_hint.0 & structs::nsRestyleHint_eRestyle_CSSAnimations.0) == 0,
|
||||
"eRestyle_CSSAnimations should only appear by itself");
|
||||
restyle_hint == structs::nsRestyleHint_eRestyle_CSSTransitions ||
|
||||
(restyle_hint.0 & (structs::nsRestyleHint_eRestyle_CSSAnimations.0 |
|
||||
structs::nsRestyleHint_eRestyle_CSSTransitions.0)) == 0,
|
||||
"eRestyle_CSSAnimations or eRestyle_CSSTransitions should only appear by itself");
|
||||
|
||||
let mut maybe_data = element.mutate_data();
|
||||
let maybe_restyle_data = maybe_data.as_mut().and_then(|d| unsafe {
|
||||
maybe_restyle(d, element, restyle_hint == structs::nsRestyleHint_eRestyle_CSSAnimations)
|
||||
maybe_restyle(d, element, restyle_hint == structs::nsRestyleHint_eRestyle_CSSAnimations ||
|
||||
restyle_hint == structs::nsRestyleHint_eRestyle_CSSTransitions)
|
||||
});
|
||||
if let Some(restyle_data) = maybe_restyle_data {
|
||||
let restyle_hint: RestyleHint = restyle_hint.into();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue