OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/favicon/favicon_service.h" | 5 #include "components/favicon/core/browser/favicon_service.h" |
6 | 6 |
7 #include <cmath> | 7 #include <cmath> |
8 | 8 |
9 #include "base/hash.h" | 9 #include "base/hash.h" |
10 #include "base/single_thread_task_runner.h" | 10 #include "base/single_thread_task_runner.h" |
11 #include "base/thread_task_runner_handle.h" | 11 #include "base/thread_task_runner_handle.h" |
12 #include "components/favicon/core/browser/favicon_client.h" | 12 #include "components/favicon/core/browser/favicon_client.h" |
13 #include "components/favicon_base/favicon_util.h" | 13 #include "components/favicon_base/favicon_util.h" |
14 #include "components/favicon_base/select_favicon_frames.h" | 14 #include "components/favicon_base/select_favicon_frames.h" |
15 #include "components/history/core/browser/history_service.h" | 15 #include "components/history/core/browser/history_service.h" |
(...skipping 366 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
382 if (!gfx::PNGCodec::EncodeBGRASkBitmap(resized_image.AsBitmap(), false, | 382 if (!gfx::PNGCodec::EncodeBGRASkBitmap(resized_image.AsBitmap(), false, |
383 &resized_bitmap_data)) { | 383 &resized_bitmap_data)) { |
384 callback.Run(favicon_base::FaviconRawBitmapResult()); | 384 callback.Run(favicon_base::FaviconRawBitmapResult()); |
385 return; | 385 return; |
386 } | 386 } |
387 | 387 |
388 bitmap_result.bitmap_data = base::RefCountedBytes::TakeVector( | 388 bitmap_result.bitmap_data = base::RefCountedBytes::TakeVector( |
389 &resized_bitmap_data); | 389 &resized_bitmap_data); |
390 callback.Run(bitmap_result); | 390 callback.Run(bitmap_result); |
391 } | 391 } |
OLD | NEW |