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

Unified Diff: ui/views/controls/progress_bar.cc

Issue 9544001: ui: Let skia do the conversion work for us by using the integer version of set() function. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: peter review Created 8 years, 10 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 | « ui/views/controls/menu/menu_image_util.cc ('k') | ui/views/painter.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/controls/progress_bar.cc
diff --git a/ui/views/controls/progress_bar.cc b/ui/views/controls/progress_bar.cc
index 14966c75cc40b6f67bdaf6eb9b172e84c81e74da..353181bde53d3d927c4172e59a71ebc7e6baabc4 100644
--- a/ui/views/controls/progress_bar.cc
+++ b/ui/views/controls/progress_bar.cc
@@ -76,11 +76,11 @@ void FillRoundRect(gfx::Canvas* canvas,
paint.setFlags(SkPaint::kAntiAlias_Flag);
SkPoint p[2];
- p[0].set(SkIntToScalar(x), SkIntToScalar(y));
+ p[0].iset(x, y);
if (gradient_horizontal) {
- p[1].set(SkIntToScalar(x + w), SkIntToScalar(y));
+ p[1].iset(x + w, y);
} else {
- p[1].set(SkIntToScalar(x), SkIntToScalar(y + h));
+ p[1].iset(x, y + h);
}
SkShader* s = SkGradientShader::CreateLinear(
p, colors, points, count, SkShader::kClamp_TileMode, NULL);
« no previous file with comments | « ui/views/controls/menu/menu_image_util.cc ('k') | ui/views/painter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698