Files
desktop/src/gfx/layers/AnimationInfo-cpp.patch

30 lines
1.4 KiB
C++

diff --git a/gfx/layers/AnimationInfo.cpp b/gfx/layers/AnimationInfo.cpp
index 538808aa15d1902fc517f79e3a6d62f4d7fd9d37..4b0760b7be9d872a926f99716d16f3f64dcb2378 100644
--- a/gfx/layers/AnimationInfo.cpp
+++ b/gfx/layers/AnimationInfo.cpp
@@ -18,6 +18,7 @@
#include "mozilla/layers/AnimationStorageData.h"
#include "mozilla/layers/CompositorThread.h"
#include "mozilla/layers/WebRenderLayerManager.h"
+#include "mozilla/nsZenBoostsBackend.h"
#include "nsIContent.h"
#include "nsLayoutUtils.h"
#include "nsRefreshDriver.h"
@@ -367,9 +368,13 @@ static void SetAnimatable(NonCustomCSSPropertyId aProperty,
case eCSSProperty_background_color: {
// We don't support color animation on the compositor yet so that we can
// resolve currentColor at this moment.
- nscolor foreground =
- aFrame->Style()->GetVisitedDependentColor(&nsStyleText::mColor);
- aAnimatable = aAnimationValue.GetColor(foreground);
+ nscolor foreground = aFrame->Style()->GetVisitedDependentColor(
+ &nsStyleText::mColor, nullptr);
+ nscolor resolved = aAnimationValue.GetColor(foreground);
+ aAnimatable = aAnimationValue.IsCurrentColor()
+ ? resolved
+ : zen::nsZenBoostsBackend::ResolveStyleColor(resolved,
+ aFrame);
break;
}
case eCSSProperty_opacity: