Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(243)

Unified Diff: third_party/WebKit/Source/core/css/CSSGradientValue.cpp

Issue 2754783003: Remove two Gradient setters (Closed)
Patch Set: Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceLinearGradient.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/css/CSSGradientValue.cpp
diff --git a/third_party/WebKit/Source/core/css/CSSGradientValue.cpp b/third_party/WebKit/Source/core/css/CSSGradientValue.cpp
index 7887781901993dfdfa18d81660c95b5f9c319f19..05cfdb59c27f6e4224f25a1abacbb39141e07a2d 100644
--- a/third_party/WebKit/Source/core/css/CSSGradientValue.cpp
+++ b/third_party/WebKit/Source/core/css/CSSGradientValue.cpp
@@ -878,10 +878,10 @@ PassRefPtr<Gradient> CSSLinearGradientValue::createGradient(
}
}
- RefPtr<Gradient> gradient = Gradient::create(firstPoint, secondPoint);
-
- gradient->setSpreadMethod(m_repeating ? SpreadMethodRepeat : SpreadMethodPad);
- gradient->setDrawsInPMColorSpace(true);
+ RefPtr<Gradient> gradient =
+ Gradient::create(firstPoint, secondPoint,
+ m_repeating ? SpreadMethodRepeat : SpreadMethodPad,
+ Gradient::ColorInterpolation::Premultiplied);
// Now add the stops.
addStops(gradient.get(), conversionData, object);
@@ -1247,10 +1247,9 @@ PassRefPtr<Gradient> CSSRadialGradientValue::createGradient(
RefPtr<Gradient> gradient =
Gradient::create(firstPoint, firstRadius, secondPoint,
isDegenerate ? 0 : secondRadius.width(),
- isDegenerate ? 1 : secondRadius.aspectRatio());
-
- gradient->setSpreadMethod(m_repeating ? SpreadMethodRepeat : SpreadMethodPad);
- gradient->setDrawsInPMColorSpace(true);
+ isDegenerate ? 1 : secondRadius.aspectRatio(),
+ m_repeating ? SpreadMethodRepeat : SpreadMethodPad,
+ Gradient::ColorInterpolation::Premultiplied);
// Now add the stops.
addStops(gradient.get(), conversionData, object);
« no previous file with comments | « no previous file | third_party/WebKit/Source/core/layout/svg/LayoutSVGResourceLinearGradient.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698