OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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/thumbnails/content_based_thumbnailing_algorithm.h" | 5 #include "chrome/browser/thumbnails/content_based_thumbnailing_algorithm.h" |
6 | 6 |
| 7 #include <stddef.h> |
| 8 |
7 #include "base/metrics/histogram.h" | 9 #include "base/metrics/histogram.h" |
8 #include "base/threading/sequenced_worker_pool.h" | 10 #include "base/threading/sequenced_worker_pool.h" |
9 #include "chrome/browser/thumbnails/content_analysis.h" | 11 #include "chrome/browser/thumbnails/content_analysis.h" |
10 #include "chrome/browser/thumbnails/simple_thumbnail_crop.h" | 12 #include "chrome/browser/thumbnails/simple_thumbnail_crop.h" |
11 #include "content/public/browser/browser_thread.h" | 13 #include "content/public/browser/browser_thread.h" |
12 #include "third_party/skia/include/core/SkBitmap.h" | 14 #include "third_party/skia/include/core/SkBitmap.h" |
13 #include "ui/gfx/color_utils.h" | 15 #include "ui/gfx/color_utils.h" |
14 #include "ui/gfx/geometry/size_conversions.h" | 16 #include "ui/gfx/geometry/size_conversions.h" |
15 #include "ui/gfx/scrollbar_size.h" | 17 #include "ui/gfx/scrollbar_size.h" |
16 #include "ui/gfx/skbitmap_operations.h" | 18 #include "ui/gfx/skbitmap_operations.h" |
(...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
233 } else { | 235 } else { |
234 clipping_rect = gfx::Rect(source_size); | 236 clipping_rect = gfx::Rect(source_size); |
235 target_size->SetSize(source_size.width() / 2, source_size.height() / 2); | 237 target_size->SetSize(source_size.width() / 2, source_size.height() / 2); |
236 *clip_result = CLIP_RESULT_NOT_CLIPPED; | 238 *clip_result = CLIP_RESULT_NOT_CLIPPED; |
237 } | 239 } |
238 | 240 |
239 return clipping_rect; | 241 return clipping_rect; |
240 } | 242 } |
241 | 243 |
242 } // namespace thumbnails | 244 } // namespace thumbnails |
OLD | NEW |