mirror of
https://github.com/servo/servo.git
synced 2025-10-01 00:59:15 +01:00
style: Handle Shadow DOM in keyframes lookup.
Bug: 1018269 Reviewed-by: heycam MozReview-Commit-ID: AeUmsOHOUYR
This commit is contained in:
parent
40a616920c
commit
4f161d9339
2 changed files with 49 additions and 10 deletions
|
@ -4768,17 +4768,18 @@ fn fill_in_missing_keyframe_values(
|
|||
#[no_mangle]
|
||||
pub unsafe extern "C" fn Servo_StyleSet_GetKeyframesForName(
|
||||
raw_data: RawServoStyleSetBorrowed,
|
||||
element: RawGeckoElementBorrowed,
|
||||
name: *mut nsAtom,
|
||||
inherited_timing_function: nsTimingFunctionBorrowed,
|
||||
keyframes: RawGeckoKeyframeListBorrowedMut,
|
||||
) -> bool {
|
||||
debug_assert!(keyframes.len() == 0,
|
||||
"keyframes should be initially empty");
|
||||
debug_assert!(keyframes.len() == 0, "keyframes should be initially empty");
|
||||
|
||||
let element = GeckoElement(element);
|
||||
let data = PerDocumentStyleData::from_ffi(raw_data).borrow();
|
||||
let name = Atom::from_raw(name);
|
||||
|
||||
let animation = match data.stylist.get_animation(&name) {
|
||||
let animation = match data.stylist.get_animation(&name, element) {
|
||||
Some(animation) => animation,
|
||||
None => return false,
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue