Index: Source/core/animation/ElementAnimations.cpp |
diff --git a/Source/core/animation/ElementAnimations.cpp b/Source/core/animation/ElementAnimations.cpp |
index 86500eca222de8ac8b5f370b13498a3558e4425b..598a71b1065f6729f6088ec7d4475f8f405dde94 100644 |
--- a/Source/core/animation/ElementAnimations.cpp |
+++ b/Source/core/animation/ElementAnimations.cpp |
@@ -117,4 +117,15 @@ void ElementAnimations::clearBaseLayoutStyle() |
m_baseLayoutStyle = nullptr; |
} |
+bool ElementAnimations::isAnimationStyleChange() const |
+{ |
+ // TODO(rune@opera.com): The FontFaceCache version number may be increased without forcing |
+ // a style recalc (see crbug.com/471079). LayoutStyle objects created with different cache |
+ // versions will not be considered equal as Font::operator== will compare versions, hence |
+ // LayoutStyle::operator== will return false. We avoid using baseLayoutStyle (the check for |
+ // isFallbackValid()) in that case to avoid triggering the LayoutStyle comparison ASSERT |
+ // in updateBaseLayoutStyle. |
+ return m_animationStyleChange && (!m_baseLayoutStyle || m_baseLayoutStyle->font().isFallbackValid()); |
+} |
+ |
} // namespace blink |