blob: b091d07b862b1861ea8d78cadff0bef8062b69de (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
|
// 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.
#include "cc/test/fake_content_layer_impl.h"
namespace cc {
FakeContentLayerImpl::FakeContentLayerImpl(LayerTreeImpl* tree_impl, int id)
: TiledLayerImpl(tree_impl, id),
lost_output_surface_count_(0),
append_quads_count_(0) {
}
FakeContentLayerImpl::~FakeContentLayerImpl() {}
scoped_ptr<LayerImpl> FakeContentLayerImpl::CreateLayerImpl(
LayerTreeImpl* tree_impl) {
return FakeContentLayerImpl::Create(tree_impl, id()).PassAs<LayerImpl>();
}
bool FakeContentLayerImpl::HaveResourceForTileAt(int i, int j) {
return HasResourceIdForTileAt(i, j);
}
void FakeContentLayerImpl::ReleaseResources() {
TiledLayerImpl::ReleaseResources();
++lost_output_surface_count_;
}
void FakeContentLayerImpl::AppendQuads(QuadSink* quad_sink,
AppendQuadsData* append_quads_data) {
TiledLayerImpl::AppendQuads(quad_sink, append_quads_data);
++append_quads_count_;
}
} // namespace cc
|