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

Unified Diff: ui/views/color_chooser/color_chooser_view.cc

Issue 2893083002: cc: Move SkShader construction to a single spot in PaintShader (Closed)
Patch Set: update Created 3 years, 7 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
« ui/gfx/skia_paint_util.h ('K') | « ui/native_theme/native_theme_base.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/color_chooser/color_chooser_view.cc
diff --git a/ui/views/color_chooser/color_chooser_view.cc b/ui/views/color_chooser/color_chooser_view.cc
index 4daa497ad9bcab6fb2c8429436c5b348fbc67904..49ab0d282ff253cdeb0e8a314116a25eeb8a806f 100644
--- a/ui/views/color_chooser/color_chooser_view.cc
+++ b/ui/views/color_chooser/color_chooser_view.cc
@@ -104,8 +104,8 @@ void DrawGradientRect(const gfx::Rect& rect, SkColor start_color,
else
points[1].iset(0, rect.height() + 1);
cc::PaintFlags flags;
- flags.setShader(cc::WrapSkShader(SkGradientShader::MakeLinear(
- points, colors, NULL, 2, SkShader::kClamp_TileMode)));
+ flags.setShader(base::MakeUnique<cc::PaintShader>(points, colors, nullptr, 2,
+ SkShader::kClamp_TileMode));
canvas->DrawRect(rect, flags);
}
« ui/gfx/skia_paint_util.h ('K') | « ui/native_theme/native_theme_base.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698