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

Unified Diff: third_party/WebKit/Source/platform/graphics/PlaceholderImage.cpp

Issue 2559013002: Add ColorBehavior to blink::Image draw methods (Closed)
Patch Set: Rebase Created 4 years 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
Index: third_party/WebKit/Source/platform/graphics/PlaceholderImage.cpp
diff --git a/third_party/WebKit/Source/platform/graphics/PlaceholderImage.cpp b/third_party/WebKit/Source/platform/graphics/PlaceholderImage.cpp
index a2df199d0260d012e7cf1726e4bf7c21a1098531..3939060f5a3e6df69bc8378ee9fc8a2e5886fae4 100644
--- a/third_party/WebKit/Source/platform/graphics/PlaceholderImage.cpp
+++ b/third_party/WebKit/Source/platform/graphics/PlaceholderImage.cpp
@@ -27,7 +27,10 @@ const RGBA32 kFillColor = 0x66808080;
PlaceholderImage::~PlaceholderImage() {}
-sk_sp<SkImage> PlaceholderImage::imageForCurrentFrame() {
+sk_sp<SkImage> PlaceholderImage::imageForCurrentFrame(
+ const ColorBehavior& colorBehavior) {
+ // TODO(ccameron): This function should not ignore |colorBehavior|.
+ // https://crbug.com/672306
if (m_imageForCurrentFrame)
return m_imageForCurrentFrame;
@@ -52,7 +55,10 @@ void PlaceholderImage::draw(SkCanvas* canvas,
const FloatRect& destRect,
const FloatRect& srcRect,
RespectImageOrientationEnum,
- ImageClampingMode) {
+ ImageClampingMode,
+ const ColorBehavior& colorBehavior) {
+ // TODO(ccameron): This function should not ignore |colorBehavior|.
+ // https://crbug.com/672306
if (!srcRect.intersects(FloatRect(0.0f, 0.0f,
static_cast<float>(m_size.width()),
static_cast<float>(m_size.height())))) {

Powered by Google App Engine
This is Rietveld 408576698