| Index: cc/test/fake_scoped_ui_resource.cc
|
| diff --git a/cc/test/fake_scoped_ui_resource.cc b/cc/test/fake_scoped_ui_resource.cc
|
| index 02f0fa9b12f0201f82c4443400944a254a920721..cdec4a71303acb5a4df28662f9245e21fccdfe62 100644
|
| --- a/cc/test/fake_scoped_ui_resource.cc
|
| +++ b/cc/test/fake_scoped_ui_resource.cc
|
| @@ -15,15 +15,17 @@ scoped_ptr<FakeScopedUIResource> FakeScopedUIResource::Create(
|
|
|
| FakeScopedUIResource::FakeScopedUIResource(LayerTreeHost* host) {
|
| ResetCounters();
|
| - bitmap_ = UIResourceBitmap::Create(
|
| - new uint8_t[1], UIResourceBitmap::RGBA8, gfx::Size(1, 1));
|
| host_ = host;
|
| - id_ = host_->CreateUIResource(this);
|
| + SkBitmap skbitmap;
|
| + skbitmap.setConfig(SkBitmap::kARGB_8888_Config, 1, 1);
|
| + skbitmap.allocPixels();
|
| + skbitmap.setImmutable();
|
| + bitmap_ = UIResourceBitmap(skbitmap);
|
| + id_ = host->CreateUIResource(this);
|
| }
|
|
|
| -scoped_refptr<UIResourceBitmap> FakeScopedUIResource::GetBitmap(
|
| - UIResourceId uid,
|
| - bool resource_lost) {
|
| +UIResourceBitmap FakeScopedUIResource::GetBitmap(UIResourceId uid,
|
| + bool resource_lost) {
|
| resource_create_count++;
|
| if (resource_lost)
|
| lost_resource_count++;
|
|
|