| Index: third_party/WebKit/Source/core/css/resolver/StyleResolver.cpp
|
| diff --git a/third_party/WebKit/Source/core/css/resolver/StyleResolver.cpp b/third_party/WebKit/Source/core/css/resolver/StyleResolver.cpp
|
| index 2f576663e6ef833eda4cea6fa42d4172fb10743f..31527ca5f11e3f8d594ceabc2ba93eab29f13976 100644
|
| --- a/third_party/WebKit/Source/core/css/resolver/StyleResolver.cpp
|
| +++ b/third_party/WebKit/Source/core/css/resolver/StyleResolver.cpp
|
| @@ -1214,6 +1214,20 @@ StyleRuleKeyframes* StyleResolver::FindKeyframesRule(
|
| return keyframes_rule;
|
| }
|
|
|
| + // This is a workaround for crbug.com/724975. Since the keyframe rules from
|
| + // UA style sheets are not available in the resolvers, read those rules
|
| + // directly here.
|
| + if (element->IsInShadowTree() &&
|
| + ToShadowRoot(element->GetTreeScope().RootNode()).GetType() ==
|
| + ShadowRootType::kUserAgent) {
|
| + const auto& keyframe_rules =
|
| + CSSDefaultStyleSheets::Instance().DefaultStyle()->KeyframesRules();
|
| + for (const auto& rule : keyframe_rules) {
|
| + if (rule->GetName() == animation_name)
|
| + return rule;
|
| + }
|
| + }
|
| +
|
| for (auto& resolver : resolvers)
|
| resolver->SetHasUnresolvedKeyframesRule();
|
| return nullptr;
|
|
|