From b83153f1f790614b4807a607990f87557a332bfc Mon Sep 17 00:00:00 2001 From: Jocelyn Turcotte Date: Wed, 13 Nov 2013 14:17:00 +0100 Subject: Delegated renderer: implement cc::DrawQuad::SOLID_COLOR. I could currently only test this with --enable-overlay-scrollbars. Background color quads still need some work in Chromium to be able to to use this kind of quads, see . Change-Id: I9c9bdb5c72b91827cfdb7e38e44755c6361a05cf Reviewed-by: Zeno Albisser --- lib/type_conversion.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'lib/type_conversion.h') diff --git a/lib/type_conversion.h b/lib/type_conversion.h index ce3423e63..0f0a8ab60 100644 --- a/lib/type_conversion.h +++ b/lib/type_conversion.h @@ -42,12 +42,14 @@ #ifndef TYPE_CONVERSION_H #define TYPE_CONVERSION_H +#include #include #include #include #include #include "base/files/file_path.h" #include "third_party/skia/include/utils/SkMatrix44.h" +#include "third_party/skia/include/core/SkColor.h" #include "ui/gfx/rect.h" #include "url/gurl.h" @@ -96,6 +98,11 @@ inline QSizeF toQt(const gfx::SizeF &size) return QSizeF(size.width(), size.height()); } +inline QColor toQt(const SkColor &c) +{ + return QColor(SkColorGetR(c), SkColorGetG(c), SkColorGetB(c), SkColorGetA(c)); +} + inline QMatrix4x4 toQt(const SkMatrix44 &m) { return QMatrix4x4( -- cgit v1.2.3