Bug 1615083 Comment 5 Edit History

Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.

OK. There is one extra issue in this bug. It seems no one updates the cascade results after setting the new non-existing target. So when we call `nsComputedDOMStyle::GetComputedStyleNoFlush()` (by `getComputedStyle(div)` or `KeyframeEffect::GetTargetComputedStyle`), which gets animation rules for pseudos and tries to compose its style, EffectCompositor will passes [a list of properties for skip](https://searchfox.org/mozilla-central/rev/c79c0d65a183d9d38676855f455a5c6a7f7dadd3/dom/animation/EffectCompositor.cpp#416-418) into each KeyframeEffects, and I think this list is still out-of-date (because it includes `margin-left` in my case), so `KeyframeEffect::ComposeStyle()` [skips this property](https://searchfox.org/mozilla-central/rev/c79c0d65a183d9d38676855f455a5c6a7f7dadd3/dom/animation/KeyframeEffect.cpp#603-605). Therefore, `EffectCompositor::GetServoAnimationRule()` returns an empty list of animation rules. Then the tests failed.

Need to figure out how to make sure `EffectSet::PropertiesForAnimationsLevel()` is up-to-dated when setting target and pseudoElement.
OK. There is one extra issue in this bug. It seems no one updates the cascade results after setting the new non-existing target. So when we call `nsComputedDOMStyle::GetComputedStyleNoFlush()` (by `getComputedStyle(div)` or `KeyframeEffect::GetTargetComputedStyle`), which gets animation rules for pseudos and tries to compose its style, EffectCompositor will passes [a list of properties for skip](https://searchfox.org/mozilla-central/rev/c79c0d65a183d9d38676855f455a5c6a7f7dadd3/dom/animation/EffectCompositor.cpp#416-418) into each KeyframeEffects, and I think this list is still out-of-date (because it includes `margin-left` in my case), so `KeyframeEffect::ComposeStyle()` [skips this property](https://searchfox.org/mozilla-central/rev/c79c0d65a183d9d38676855f455a5c6a7f7dadd3/dom/animation/KeyframeEffect.cpp#603-605). Therefore, `EffectCompositor::GetServoAnimationRule()` returns an empty list of animation rules. Then the tests failed.

Need to figure out how to make sure `EffectSet::PropertiesForAnimationsLevel()` is up-to-dated when setting a non-existing pseudo-element.
OK. There is one extra issue in this bug. It seems no one updates the cascade results after setting the new non-existing target. So when we call `nsComputedDOMStyle::GetComputedStyleNoFlush()` (by `getComputedStyle(div)` or `KeyframeEffect::GetTargetComputedStyle`), which gets animation rules for pseudos and tries to compose its style, EffectCompositor will passes [a list of properties for skip](https://searchfox.org/mozilla-central/rev/c79c0d65a183d9d38676855f455a5c6a7f7dadd3/dom/animation/EffectCompositor.cpp#416-418) into each KeyframeEffects, and I think this list is still out-of-date (because it includes `margin-left` in my case), so `KeyframeEffect::ComposeStyle()` [skips this property](https://searchfox.org/mozilla-central/rev/c79c0d65a183d9d38676855f455a5c6a7f7dadd3/dom/animation/KeyframeEffect.cpp#603-605). Therefore, `EffectCompositor::GetServoAnimationRule()` returns an empty list of animation rules. Then the tests failed.

Need to figure out how to make sure `EffectSet::PropertiesForAnimationsLevel()` is up-to-dated when setting a non-existing pseudo-element as the new target.
OK. There is one extra issue in this bug. It seems the update of cascade results after setting the new non-existing target has issues. So when we call `nsComputedDOMStyle::GetComputedStyleNoFlush()` (by `getComputedStyle(div)` or `KeyframeEffect::GetTargetComputedStyle`), which gets animation rules for pseudos and tries to compose its style, EffectCompositor will passes [a list of properties for skip](https://searchfox.org/mozilla-central/rev/c79c0d65a183d9d38676855f455a5c6a7f7dadd3/dom/animation/EffectCompositor.cpp#416-418) into each KeyframeEffects, and I think this list is still out-of-date (because it includes `margin-left` in my case), so `KeyframeEffect::ComposeStyle()` [skips this property](https://searchfox.org/mozilla-central/rev/c79c0d65a183d9d38676855f455a5c6a7f7dadd3/dom/animation/KeyframeEffect.cpp#603-605). Therefore, `EffectCompositor::GetServoAnimationRule()` returns an empty list of animation rules. Then the tests failed.

Need to figure out how to make sure `EffectSet::PropertiesForAnimationsLevel()` is up-to-dated when setting a non-existing pseudo-element as the new target.

Back to Bug 1615083 Comment 5