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

Unified Diff: chrome/browser/ui/views/infobars/infobar_background.cc

Issue 9588003: browser: Minor changes to use SkPoint::iset() function. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . 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 | « chrome/browser/chromeos/frame/panel_controller.cc ('k') | chrome/browser/ui/views/tabs/tab.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/infobars/infobar_background.cc
diff --git a/chrome/browser/ui/views/infobars/infobar_background.cc b/chrome/browser/ui/views/infobars/infobar_background.cc
index 84399f5a4c6d494bc24260c3c2c03a1c1d0220d7..7078f9b4d6d01a31e421cd28c9877ecbe430206f 100644
--- a/chrome/browser/ui/views/infobars/infobar_background.cc
+++ b/chrome/browser/ui/views/infobars/infobar_background.cc
@@ -24,14 +24,10 @@ InfoBarBackground::~InfoBarBackground() {
}
void InfoBarBackground::Paint(gfx::Canvas* canvas, views::View* view) const {
- SkPoint gradient_points[2] = {
- {SkIntToScalar(0), SkIntToScalar(0)},
- {SkIntToScalar(0), SkIntToScalar(view->height())}
- };
- SkColor gradient_colors[2] = {
- top_color_,
- bottom_color_
- };
+ SkPoint gradient_points[2];
+ gradient_points[0].iset(0, 0);
+ gradient_points[1].iset(0, view->height());
+ SkColor gradient_colors[2] = { top_color_, bottom_color_ };
SkShader* gradient_shader = SkGradientShader::CreateLinear(
gradient_points, gradient_colors, NULL, 2, SkShader::kClamp_TileMode);
SkPaint paint;
« no previous file with comments | « chrome/browser/chromeos/frame/panel_controller.cc ('k') | chrome/browser/ui/views/tabs/tab.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698