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

Unified Diff: chrome/utility/chrome_content_utility_client.cc

Issue 17704002: Move image_decoder.cc/.h from webkit\glue to content\child. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 7 years, 6 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
« no previous file with comments | « chrome/utility/DEPS ('k') | content/child/DEPS » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/utility/chrome_content_utility_client.cc
===================================================================
--- chrome/utility/chrome_content_utility_client.cc (revision 208527)
+++ chrome/utility/chrome_content_utility_client.cc (working copy)
@@ -20,6 +20,7 @@
#include "chrome/common/safe_browsing/zip_analyzer.h"
#include "chrome/common/web_resource/web_resource_unpacker.h"
#include "chrome/utility/profile_import_handler.h"
+#include "content/public/child/image_decoder_utils.h"
#include "content/public/utility/utility_thread.h"
#include "printing/page_range.h"
#include "third_party/skia/include/core/SkBitmap.h"
@@ -27,7 +28,7 @@
#include "ui/base/ui_base_switches.h"
#include "ui/gfx/codec/jpeg_codec.h"
#include "ui/gfx/rect.h"
-#include "webkit/glue/image_decoder.h"
+#include "ui/gfx/size.h"
#if defined(OS_WIN)
#include "base/file_util.h"
@@ -195,9 +196,9 @@
void ChromeContentUtilityClient::OnDecodeImage(
const std::vector<unsigned char>& encoded_data) {
- webkit_glue::ImageDecoder decoder;
- const SkBitmap& decoded_image = decoder.Decode(&encoded_data[0],
- encoded_data.size());
+ const SkBitmap& decoded_image = content::DecodeImage(&encoded_data[0],
+ gfx::Size(),
+ encoded_data.size());
if (decoded_image.empty()) {
Send(new ChromeUtilityHostMsg_DecodeImage_Failed());
} else {
« no previous file with comments | « chrome/utility/DEPS ('k') | content/child/DEPS » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698