Index: Source/core/css/CSSGradientValue.cpp |
diff --git a/Source/core/css/CSSGradientValue.cpp b/Source/core/css/CSSGradientValue.cpp |
index 7b4e7535d05eea0cd708998c8084377881564975..4f72ea96e99380d9c743d17d8fa35e4f08ee3527 100644 |
--- a/Source/core/css/CSSGradientValue.cpp |
+++ b/Source/core/css/CSSGradientValue.cpp |
@@ -105,7 +105,7 @@ struct GradientStop { |
{ } |
}; |
-PassRefPtr<CSSGradientValue> CSSGradientValue::gradientWithStylesResolved(const TextLinkColors& textLinkColors, Color currentColor) |
+PassRefPtr<CSSGradientValue> CSSGradientValue::gradientWithStylesResolved(const TextLinkColors& textLinkColors) |
{ |
bool derived = false; |
for (unsigned i = 0; i < m_stops.size(); i++) |
@@ -128,7 +128,7 @@ PassRefPtr<CSSGradientValue> CSSGradientValue::gradientWithStylesResolved(const |
} |
for (unsigned i = 0; i < result->m_stops.size(); i++) |
- result->m_stops[i].m_resolvedColor = textLinkColors.colorFromPrimitiveValue(result->m_stops[i].m_color.get(), currentColor); |
+ result->m_stops[i].m_resolvedColor = textLinkColors.colorFromPrimitiveValue(result->m_stops[i].m_color.get()); |
return result.release(); |
} |
@@ -149,7 +149,7 @@ void CSSGradientValue::addStops(Gradient* gradient, RenderObject* renderer, Rend |
else |
offset = stop.m_position->getFloatValue(CSSPrimitiveValue::CSS_NUMBER); |
- gradient->addColorStop(offset, stop.m_resolvedColor); |
+ gradient->addColorStop(offset, renderer->resolveColor(stop.m_resolvedColor)); |
} |
// The back end already sorted the stops. |
@@ -174,7 +174,7 @@ void CSSGradientValue::addStops(Gradient* gradient, RenderObject* renderer, Rend |
for (size_t i = 0; i < numStops; ++i) { |
const CSSGradientColorStop& stop = m_stops[i]; |
- stops[i].color = stop.m_resolvedColor; |
+ stops[i].color = renderer->resolveColor(stop.m_resolvedColor); |
if (stop.m_position) { |
if (stop.m_position->isPercentage()) |