OLD | NEW |
1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CC_TEST_FAKE_PICTURE_LAYER_H_ | 5 #ifndef CC_TEST_FAKE_PICTURE_LAYER_H_ |
6 #define CC_TEST_FAKE_PICTURE_LAYER_H_ | 6 #define CC_TEST_FAKE_PICTURE_LAYER_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 | 9 |
10 #include <memory> | 10 #include <memory> |
(...skipping 24 matching lines...) Expand all Loading... |
35 void reset_update_count() { update_count_ = 0; } | 35 void reset_update_count() { update_count_ = 0; } |
36 | 36 |
37 void set_always_update_resources(bool always_update_resources) { | 37 void set_always_update_resources(bool always_update_resources) { |
38 always_update_resources_ = always_update_resources; | 38 always_update_resources_ = always_update_resources; |
39 } | 39 } |
40 | 40 |
41 void set_force_unsuitable_for_gpu_rasterization(bool flag) { | 41 void set_force_unsuitable_for_gpu_rasterization(bool flag) { |
42 force_unsuitable_for_gpu_rasterization_ = flag; | 42 force_unsuitable_for_gpu_rasterization_ = flag; |
43 } | 43 } |
44 | 44 |
| 45 void set_fixed_tile_size(gfx::Size fixed_tile_size) { |
| 46 fixed_tile_size_ = fixed_tile_size; |
| 47 } |
| 48 |
45 private: | 49 private: |
46 explicit FakePictureLayer(ContentLayerClient* client); | 50 explicit FakePictureLayer(ContentLayerClient* client); |
47 FakePictureLayer(ContentLayerClient* client, | 51 FakePictureLayer(ContentLayerClient* client, |
48 std::unique_ptr<RecordingSource> source); | 52 std::unique_ptr<RecordingSource> source); |
49 ~FakePictureLayer() override; | 53 ~FakePictureLayer() override; |
50 | 54 |
51 int update_count_; | 55 int update_count_; |
52 bool always_update_resources_; | 56 bool always_update_resources_; |
53 | 57 |
54 bool force_unsuitable_for_gpu_rasterization_; | 58 bool force_unsuitable_for_gpu_rasterization_; |
| 59 gfx::Size fixed_tile_size_; |
55 }; | 60 }; |
56 | 61 |
57 } // namespace cc | 62 } // namespace cc |
58 | 63 |
59 #endif // CC_TEST_FAKE_PICTURE_LAYER_H_ | 64 #endif // CC_TEST_FAKE_PICTURE_LAYER_H_ |
OLD | NEW |