| Index: Source/core/css/CSSComputedStyleDeclaration.cpp
|
| diff --git a/Source/core/css/CSSComputedStyleDeclaration.cpp b/Source/core/css/CSSComputedStyleDeclaration.cpp
|
| index 5f37acf43383dd249aca76f37987bd19da1df0be..040126d7cf190eafce0188ed5829b02ed42bd02f 100644
|
| --- a/Source/core/css/CSSComputedStyleDeclaration.cpp
|
| +++ b/Source/core/css/CSSComputedStyleDeclaration.cpp
|
| @@ -29,6 +29,9 @@
|
| #include "RuntimeEnabledFeatures.h"
|
| #include "StylePropertyShorthand.h"
|
| #include "bindings/v8/ExceptionState.h"
|
| +#include "core/animation/ActiveAnimations.h"
|
| +#include "core/animation/AnimationClock.h"
|
| +#include "core/animation/DocumentTimeline.h"
|
| #include "core/css/BasicShapeFunctions.h"
|
| #include "core/css/CSSArrayFunctionValue.h"
|
| #include "core/css/CSSAspectRatioValue.h"
|
| @@ -1620,6 +1623,16 @@ PassRefPtr<CSSValue> CSSComputedStyleDeclaration::getPropertyCSSValue(CSSPropert
|
| if (updateLayout) {
|
| Document& document = styledNode->document();
|
|
|
| + // If a compositor animation is running we may need to service animations
|
| + // in order to generate an up to date value.
|
| + if (RuntimeEnabledFeatures::webAnimationsCSSEnabled() && styledNode->isElementNode()) {
|
| + const Element* element = toElement(styledNode);
|
| + if (const ActiveAnimations* activeAnimations = element->activeAnimations()) {
|
| + if (activeAnimations->hasActiveAnimationsOnCompositor(propertyID))
|
| + document.serviceAnimations(monotonicallyIncreasingTime());
|
| + }
|
| + }
|
| +
|
| document.updateStyleForNodeIfNeeded(styledNode);
|
|
|
| // The style recalc could have caused the styled node to be discarded or replaced
|
|
|