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

Unified Diff: cc/test/fake_scrollbar.cc

Issue 2710153004: cc: Fix up code to work with concrete cc paint types (Closed)
Patch Set: Rebase Created 3 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 | « cc/test/fake_raster_source.cc ('k') | cc/test/skia_common.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/fake_scrollbar.cc
diff --git a/cc/test/fake_scrollbar.cc b/cc/test/fake_scrollbar.cc
index e27656370cf767606625899cc8da98681a88daba..7ddafd486ce56c8fafe9ba5cde2c45167f338989 100644
--- a/cc/test/fake_scrollbar.cc
+++ b/cc/test/fake_scrollbar.cc
@@ -4,6 +4,7 @@
#include "cc/test/fake_scrollbar.h"
+#include "cc/paint/paint_flags.h"
#include "ui/gfx/skia_util.h"
namespace cc {
@@ -78,16 +79,16 @@ void FakeScrollbar::PaintPart(PaintCanvas* canvas,
// Fill the scrollbar with a different color each time.
fill_color_++;
- SkPaint paint;
- paint.setAntiAlias(false);
- paint.setColor(paint_fill_color());
- paint.setStyle(SkPaint::kFill_Style);
+ PaintFlags flags;
+ flags.setAntiAlias(false);
+ flags.setColor(paint_fill_color());
+ flags.setStyle(PaintFlags::kFill_Style);
// Emulate the how the real scrollbar works by using scrollbar's rect for
// TRACK and the given content_rect for the THUMB
SkRect rect = part == TRACK ? RectToSkRect(TrackRect())
: RectToSkRect(content_rect);
- canvas->drawRect(rect, paint);
+ canvas->drawRect(rect, flags);
}
} // namespace cc
« no previous file with comments | « cc/test/fake_raster_source.cc ('k') | cc/test/skia_common.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698