From 39f121a371d153d9beb6c3e1742f0c10bfda7c80 Mon Sep 17 00:00:00 2001 From: "pkotwicz@chromium.org" Date: Mon, 14 May 2012 00:30:31 +0000 Subject: Get rid of Image::Image(SkBitmap*) Bug=124566 Test=Compiles on CrOS,Mac Review URL: https://chromiumcodereview.appspot.com/10378009 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@136812 0039d316-1c4b-4281-b951-d872f2087c98 --- ui/base/resource/resource_bundle.cc | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'ui/base') diff --git a/ui/base/resource/resource_bundle.cc b/ui/base/resource/resource_bundle.cc index f84e8db..9de5a4f 100644 --- a/ui/base/resource/resource_bundle.cc +++ b/ui/base/resource/resource_bundle.cc @@ -467,10 +467,10 @@ gfx::Image& ResourceBundle::GetEmptyImage() { if (empty_image_.IsEmpty()) { // The placeholder bitmap is bright red so people notice the problem. - SkBitmap* bitmap = new SkBitmap(); - bitmap->setConfig(SkBitmap::kARGB_8888_Config, 32, 32); - bitmap->allocPixels(); - bitmap->eraseARGB(255, 255, 0, 0); + SkBitmap bitmap; + bitmap.setConfig(SkBitmap::kARGB_8888_Config, 32, 32); + bitmap.allocPixels(); + bitmap.eraseARGB(255, 255, 0, 0); empty_image_ = gfx::Image(bitmap); } return empty_image_; -- cgit v1.1