diff options
author | tfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-03-06 19:35:38 +0000 |
---|---|---|
committer | tfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-03-06 19:35:38 +0000 |
commit | 85f1ee1d545b7d7874969ea5fe7e63fef7d2b0c5 (patch) | |
tree | bb253dbea59012936c295988aeb14769100871f9 /ui/views/painter.cc | |
parent | 827dd68138102ad248544775cb50def6bf8a4933 (diff) | |
download | chromium_src-85f1ee1d545b7d7874969ea5fe7e63fef7d2b0c5.zip chromium_src-85f1ee1d545b7d7874969ea5fe7e63fef7d2b0c5.tar.gz chromium_src-85f1ee1d545b7d7874969ea5fe7e63fef7d2b0c5.tar.bz2 |
views: Do not use deprecated ResourceBundle::GetBitmapNamed() function.
Instead use the recommended ResourceBundle::GetImageNamed() function and
convert it to the native type appropriately.
BUG=58030
R=sky@chromium.org
Review URL: https://chromiumcodereview.appspot.com/9597022
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@125201 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ui/views/painter.cc')
-rw-r--r-- | ui/views/painter.cc | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/ui/views/painter.cc b/ui/views/painter.cc index 38e90d6..f768445 100644 --- a/ui/views/painter.cc +++ b/ui/views/painter.cc @@ -10,6 +10,7 @@ #include "ui/base/resource/resource_bundle.h" #include "ui/gfx/canvas.h" #include "ui/gfx/canvas_skia.h" +#include "ui/gfx/image/image.h" #include "ui/gfx/insets.h" #include "ui/gfx/point.h" #include "ui/gfx/rect.h" @@ -179,9 +180,9 @@ Painter* Painter::CreateImagePainter(const SkBitmap& image, } HorizontalPainter::HorizontalPainter(const int image_resource_names[]) { - ResourceBundle& rb = ResourceBundle::GetSharedInstance(); + ui::ResourceBundle& rb = ui::ResourceBundle::GetSharedInstance(); for (int i = 0; i < 3; ++i) - images_[i] = rb.GetBitmapNamed(image_resource_names[i]); + images_[i] = rb.GetImageNamed(image_resource_names[i]).ToSkBitmap(); height_ = images_[LEFT]->height(); DCHECK(images_[LEFT]->height() == images_[RIGHT]->height() && images_[LEFT]->height() == images_[CENTER]->height()); |