Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2163)

Unified Diff: app/resource_bundle.cc

Issue 243076: Move the JPEG and PNG codecs from base/gfx to app/gfx/codec. Move the classes... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: app/resource_bundle.cc
===================================================================
--- app/resource_bundle.cc (revision 27832)
+++ app/resource_bundle.cc (working copy)
@@ -4,8 +4,8 @@
#include "app/resource_bundle.h"
+#include "app/gfx/codec/png_codec.h"
#include "app/gfx/font.h"
-#include "base/gfx/png_decoder.h"
#include "base/logging.h"
#include "base/string_piece.h"
#include "net/base/file_stream.h"
@@ -80,16 +80,16 @@
// Decode the PNG.
int image_width;
int image_height;
- if (!PNGDecoder::Decode(&raw_data.front(), raw_data.size(),
- PNGDecoder::FORMAT_BGRA,
- &png_data, &image_width, &image_height)) {
+ if (!gfx::PNGCodec::Decode(&raw_data.front(), raw_data.size(),
+ gfx::PNGCodec::FORMAT_BGRA,
+ &png_data, &image_width, &image_height)) {
NOTREACHED() << "Unable to decode image resource " << resource_id;
return NULL;
}
- return PNGDecoder::CreateSkBitmapFromBGRAFormat(png_data,
- image_width,
- image_height);
+ return gfx::PNGCodec::CreateSkBitmapFromBGRAFormat(png_data,
+ image_width,
+ image_height);
}
std::string ResourceBundle::GetDataResource(int resource_id) {
« no previous file with comments | « app/gfx/codec/png_codec_unittest.cc ('k') | base/base.gyp » ('j') | build/common.gypi » ('J')

Powered by Google App Engine
This is Rietveld 408576698