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

Unified Diff: cc/test/fake_content_layer_client.h

Issue 1057283003: Remove parts of //cc we aren't using (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 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/test/fake_content_layer.cc ('k') | cc/test/fake_content_layer_client.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/test/fake_content_layer_client.h
diff --git a/cc/test/fake_content_layer_client.h b/cc/test/fake_content_layer_client.h
deleted file mode 100644
index d53d34e2ea3d95ef6e716339de53df332396aa92..0000000000000000000000000000000000000000
--- a/cc/test/fake_content_layer_client.h
+++ /dev/null
@@ -1,75 +0,0 @@
-// Copyright 2012 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.
-
-#ifndef CC_TEST_FAKE_CONTENT_LAYER_CLIENT_H_
-#define CC_TEST_FAKE_CONTENT_LAYER_CLIENT_H_
-
-#include <utility>
-#include <vector>
-
-#include "base/compiler_specific.h"
-#include "cc/layers/content_layer_client.h"
-#include "third_party/skia/include/core/SkBitmap.h"
-#include "third_party/skia/include/core/SkPaint.h"
-#include "ui/gfx/geometry/rect.h"
-
-namespace cc {
-
-class FakeContentLayerClient : public ContentLayerClient {
- public:
- struct BitmapData {
- SkBitmap bitmap;
- gfx::Point point;
- SkPaint paint;
- };
-
- FakeContentLayerClient();
- ~FakeContentLayerClient() override;
-
- void PaintContents(SkCanvas* canvas,
- const gfx::Rect& rect,
- PaintingControlSetting painting_control) override;
- scoped_refptr<DisplayItemList> PaintContentsToDisplayList(
- const gfx::Rect& clip,
- PaintingControlSetting painting_control) override;
- bool FillsBoundsCompletely() const override;
-
- void set_fill_with_nonsolid_color(bool nonsolid) {
- fill_with_nonsolid_color_ = nonsolid;
- }
-
- void add_draw_rect(const gfx::RectF& rect, const SkPaint& paint) {
- draw_rects_.push_back(std::make_pair(rect, paint));
- }
-
- void add_draw_bitmap(const SkBitmap& bitmap,
- const gfx::Point& point,
- const SkPaint& paint) {
- BitmapData data;
- data.bitmap = bitmap;
- data.point = point;
- data.paint = paint;
- draw_bitmaps_.push_back(data);
- }
-
- SkCanvas* last_canvas() const { return last_canvas_; }
-
- PaintingControlSetting last_painting_control() const {
- return last_painting_control_;
- }
-
- private:
- typedef std::vector<std::pair<gfx::RectF, SkPaint>> RectPaintVector;
- typedef std::vector<BitmapData> BitmapVector;
-
- bool fill_with_nonsolid_color_;
- RectPaintVector draw_rects_;
- BitmapVector draw_bitmaps_;
- SkCanvas* last_canvas_;
- PaintingControlSetting last_painting_control_;
-};
-
-} // namespace cc
-
-#endif // CC_TEST_FAKE_CONTENT_LAYER_CLIENT_H_
« no previous file with comments | « cc/test/fake_content_layer.cc ('k') | cc/test/fake_content_layer_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698