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

Unified Diff: Source/platform/graphics/Gradient.cpp

Issue 785823002: use factory for colorshader, class is deprecated (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years 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 | « Source/platform/graphics/BitmapPattern.cpp ('k') | Source/platform/graphics/StaticBitmapPattern.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/platform/graphics/Gradient.cpp
diff --git a/Source/platform/graphics/Gradient.cpp b/Source/platform/graphics/Gradient.cpp
index 76d0f27d2b878ffcfe70a69c1d246b6563d8c604..1f21b5bad88d7fbec1647d2f4a50c102377a8673 100644
--- a/Source/platform/graphics/Gradient.cpp
+++ b/Source/platform/graphics/Gradient.cpp
@@ -32,7 +32,6 @@
#include "platform/graphics/GraphicsContext.h"
#include "platform/graphics/skia/SkiaUtils.h"
#include "third_party/skia/include/core/SkColor.h"
-#include "third_party/skia/include/core/SkColorShader.h"
#include "third_party/skia/include/core/SkShader.h"
#include "third_party/skia/include/effects/SkGradientShader.h"
@@ -260,7 +259,7 @@ SkShader* Gradient::shader()
if (!m_gradient) {
// use last color, since our "geometry" was degenerate (e.g. radius==0)
- m_gradient = adoptRef(new SkColorShader(colors[countUsed - 1]));
+ m_gradient = adoptRef(SkShader::CreateColorShader(colors[countUsed - 1]));
}
return m_gradient.get();
}
« no previous file with comments | « Source/platform/graphics/BitmapPattern.cpp ('k') | Source/platform/graphics/StaticBitmapPattern.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698