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

Unified Diff: cc/playback/skip_image_canvas.cc

Issue 2748263002: Move cc::DisplayItemList and related classes into cc/paint/ (Closed)
Patch Set: Merge branch 'master' into ccpaint Created 3 years, 9 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/playback/skip_image_canvas.h ('k') | cc/playback/transform_display_item.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/playback/skip_image_canvas.cc
diff --git a/cc/playback/skip_image_canvas.cc b/cc/playback/skip_image_canvas.cc
deleted file mode 100644
index 27926be145b794e04a98c015dbb0d32ceda598a4..0000000000000000000000000000000000000000
--- a/cc/playback/skip_image_canvas.cc
+++ /dev/null
@@ -1,33 +0,0 @@
-// Copyright 2016 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "cc/playback/skip_image_canvas.h"
-
-#include "third_party/skia/include/core/SkShader.h"
-
-namespace cc {
-
-SkipImageCanvas::SkipImageCanvas(SkCanvas* canvas)
- : SkPaintFilterCanvas(canvas) {}
-
-bool SkipImageCanvas::onFilter(SkTCopyOnFirstWrite<SkPaint>* paint,
- Type type) const {
- if (type == kBitmap_Type)
- return false;
-
- SkShader* shader = (*paint) ? (*paint)->getShader() : nullptr;
- return !shader || !shader->isAImage();
-}
-
-void SkipImageCanvas::onDrawPicture(const SkPicture* picture,
- const SkMatrix* matrix,
- const SkPaint* paint) {
- SkTCopyOnFirstWrite<SkPaint> filteredPaint(paint);
-
- // To filter nested draws, we must unfurl pictures at this stage.
- if (onFilter(&filteredPaint, kPicture_Type))
- SkCanvas::onDrawPicture(picture, matrix, filteredPaint);
-}
-
-} // namespace cc
« no previous file with comments | « cc/playback/skip_image_canvas.h ('k') | cc/playback/transform_display_item.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698