OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/renderer/chrome_render_view_observer.h" | 5 #include "chrome/renderer/chrome_render_view_observer.h" |
6 | 6 |
7 #include "base/command_line.h" | 7 #include "base/command_line.h" |
8 #include "base/message_loop.h" | 8 #include "base/message_loop.h" |
9 #include "base/metrics/histogram.h" | 9 #include "base/metrics/histogram.h" |
10 #include "base/string_util.h" | 10 #include "base/string_util.h" |
11 #include "chrome/common/chrome_constants.h" | 11 #include "chrome/common/chrome_constants.h" |
12 #include "chrome/common/chrome_switches.h" | 12 #include "chrome/common/chrome_switches.h" |
13 #include "chrome/common/icon_messages.h" | 13 #include "chrome/common/icon_messages.h" |
14 #include "chrome/common/render_messages.h" | 14 #include "chrome/common/render_messages.h" |
15 #include "chrome/common/thumbnail_score.h" | 15 #include "chrome/common/thumbnail_score.h" |
16 #include "chrome/common/url_constants.h" | 16 #include "chrome/common/url_constants.h" |
17 #include "chrome/renderer/about_handler.h" | 17 #include "chrome/renderer/about_handler.h" |
18 #include "chrome/renderer/automation/dom_automation_controller.h" | 18 #include "chrome/renderer/automation/dom_automation_controller.h" |
19 #include "chrome/renderer/chrome_render_process_observer.h" | 19 #include "chrome/renderer/chrome_render_process_observer.h" |
20 #include "chrome/renderer/content_settings_observer.h" | 20 #include "chrome/renderer/content_settings_observer.h" |
21 #include "chrome/renderer/extensions/extension_dispatcher.h" | 21 #include "chrome/renderer/extensions/extension_dispatcher.h" |
22 #include "chrome/renderer/external_host_bindings.h" | 22 #include "chrome/renderer/external_host_bindings.h" |
23 #include "chrome/renderer/frame_sniffer.h" | 23 #include "chrome/renderer/frame_sniffer.h" |
24 #include "chrome/renderer/prerender/prerender_helper.h" | 24 #include "chrome/renderer/prerender/prerender_helper.h" |
25 #include "chrome/renderer/safe_browsing/phishing_classifier_delegate.h" | 25 #include "chrome/renderer/safe_browsing/phishing_classifier_delegate.h" |
26 #include "chrome/renderer/translate_helper.h" | 26 #include "chrome/renderer/translate_helper.h" |
27 #include "content/common/bindings_policy.h" | 27 #include "content/common/bindings_policy.h" |
28 #include "content/common/view_messages.h" | 28 #include "content/common/view_messages.h" |
29 #include "content/renderer/content_renderer_client.h" | 29 #include "content/public/renderer/content_renderer_client.h" |
30 #include "net/base/data_url.h" | 30 #include "net/base/data_url.h" |
31 #include "skia/ext/image_operations.h" | 31 #include "skia/ext/image_operations.h" |
32 #include "skia/ext/platform_canvas.h" | 32 #include "skia/ext/platform_canvas.h" |
33 #include "third_party/WebKit/Source/WebKit/chromium/public/WebCString.h" | 33 #include "third_party/WebKit/Source/WebKit/chromium/public/WebCString.h" |
34 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDataSource.h" | 34 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDataSource.h" |
35 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDocument.h" | 35 #include "third_party/WebKit/Source/WebKit/chromium/public/WebDocument.h" |
36 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h" | 36 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrame.h" |
37 #include "third_party/WebKit/Source/WebKit/chromium/public/WebRect.h" | 37 #include "third_party/WebKit/Source/WebKit/chromium/public/WebRect.h" |
38 #include "third_party/WebKit/Source/WebKit/chromium/public/WebSize.h" | 38 #include "third_party/WebKit/Source/WebKit/chromium/public/WebSize.h" |
39 #include "third_party/WebKit/Source/WebKit/chromium/public/WebString.h" | 39 #include "third_party/WebKit/Source/WebKit/chromium/public/WebString.h" |
(...skipping 969 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1009 // Decode the favicon using WebKit's image decoder. | 1009 // Decode the favicon using WebKit's image decoder. |
1010 webkit_glue::ImageDecoder decoder( | 1010 webkit_glue::ImageDecoder decoder( |
1011 gfx::Size(gfx::kFaviconSize, gfx::kFaviconSize)); | 1011 gfx::Size(gfx::kFaviconSize, gfx::kFaviconSize)); |
1012 const unsigned char* src_data = | 1012 const unsigned char* src_data = |
1013 reinterpret_cast<const unsigned char*>(&data[0]); | 1013 reinterpret_cast<const unsigned char*>(&data[0]); |
1014 | 1014 |
1015 return decoder.Decode(src_data, data.size()); | 1015 return decoder.Decode(src_data, data.size()); |
1016 } | 1016 } |
1017 return SkBitmap(); | 1017 return SkBitmap(); |
1018 } | 1018 } |
OLD | NEW |