| Index: cc/trees/layer_tree_host_impl.cc
|
| diff --git a/cc/trees/layer_tree_host_impl.cc b/cc/trees/layer_tree_host_impl.cc
|
| index 870b65d89ba7b123085028c34359d4afbf122131..24d6d47eac39d1b6366af4fabeec35aceb0fc3c0 100644
|
| --- a/cc/trees/layer_tree_host_impl.cc
|
| +++ b/cc/trees/layer_tree_host_impl.cc
|
| @@ -2543,11 +2543,10 @@ void LayerTreeHostImpl::SetDebugState(
|
| SetFullRootLayerDamage();
|
| }
|
|
|
| -void LayerTreeHostImpl::CreateUIResource(
|
| - UIResourceId uid,
|
| - scoped_refptr<UIResourceBitmap> bitmap) {
|
| +void LayerTreeHostImpl::CreateUIResource(UIResourceId uid,
|
| + const UIResourceBitmap& bitmap) {
|
| DCHECK_GT(uid, 0);
|
| - DCHECK_EQ(bitmap->GetFormat(), UIResourceBitmap::RGBA8);
|
| + DCHECK_EQ(bitmap.GetFormat(), UIResourceBitmap::RGBA8);
|
|
|
| // Allow for multiple creation requests with the same UIResourceId. The
|
| // previous resource is simply deleted.
|
| @@ -2555,15 +2554,15 @@ void LayerTreeHostImpl::CreateUIResource(
|
| if (id)
|
| DeleteUIResource(uid);
|
| id = resource_provider_->CreateResource(
|
| - bitmap->GetSize(),
|
| + bitmap.GetSize(),
|
| resource_provider_->best_texture_format(),
|
| ResourceProvider::TextureUsageAny);
|
|
|
| ui_resource_map_[uid] = id;
|
| resource_provider_->SetPixels(id,
|
| - reinterpret_cast<uint8_t*>(bitmap->GetPixels()),
|
| - gfx::Rect(bitmap->GetSize()),
|
| - gfx::Rect(bitmap->GetSize()),
|
| + bitmap.GetPixels(),
|
| + gfx::Rect(bitmap.GetSize()),
|
| + gfx::Rect(bitmap.GetSize()),
|
| gfx::Vector2d(0, 0));
|
| }
|
|
|
|
|