| Index: chrome/browser/image_decoder.h
|
| diff --git a/chrome/browser/image_decoder.h b/chrome/browser/image_decoder.h
|
| index d8bda97454fab4f214441aa5624a14423f0b330e..055ccc08fe319da5408a349bacc5781992db6b47 100644
|
| --- a/chrome/browser/image_decoder.h
|
| +++ b/chrome/browser/image_decoder.h
|
| @@ -15,6 +15,10 @@
|
| #include "base/sequenced_task_runner.h"
|
| #include "base/synchronization/lock.h"
|
|
|
| +namespace gfx {
|
| +class Size;
|
| +} // namespace gfx
|
| +
|
| class SkBitmap;
|
|
|
| // This is a helper class for decoding images safely in a sandboxed service. To
|
| @@ -84,10 +88,14 @@ class ImageDecoder {
|
|
|
| // Starts asynchronous image decoding. Once finished, the callback will be
|
| // posted back to image_request's |task_runner_|.
|
| + // For images with multiple frames (e.g. ico files), we choose a frame with a
|
| + // size as close as possible to |desired_image_frame_size| (tries to take one
|
| + // in larger size if there's no precise match).
|
| static void StartWithOptions(ImageRequest* image_request,
|
| std::vector<uint8_t> image_data,
|
| ImageCodec image_codec,
|
| - bool shrink_to_fit);
|
| + bool shrink_to_fit,
|
| + const gfx::Size& desired_image_frame_size);
|
| // Deprecated. Use std::vector<uint8_t> version to avoid an extra copy.
|
| static void StartWithOptions(ImageRequest* image_request,
|
| const std::string& image_data,
|
| @@ -104,7 +112,8 @@ class ImageDecoder {
|
| void StartWithOptionsImpl(ImageRequest* image_request,
|
| std::vector<uint8_t> image_data,
|
| ImageCodec image_codec,
|
| - bool shrink_to_fit);
|
| + bool shrink_to_fit,
|
| + const gfx::Size& desired_image_frame_size);
|
|
|
| void CancelImpl(ImageRequest* image_request);
|
|
|
|
|