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/ui/webui/crashes_ui.h" | 5 #include "chrome/browser/ui/webui/crashes_ui.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include "base/bind.h" | 9 #include "base/bind.h" |
10 #include "base/bind_helpers.h" | 10 #include "base/bind_helpers.h" |
11 #include "base/macros.h" | 11 #include "base/macros.h" |
12 #include "base/memory/ref_counted_memory.h" | 12 #include "base/memory/ref_counted_memory.h" |
13 #include "base/strings/utf_string_conversions.h" | 13 #include "base/strings/utf_string_conversions.h" |
14 #include "base/sys_info.h" | 14 #include "base/sys_info.h" |
15 #include "base/values.h" | 15 #include "base/values.h" |
16 #include "build/build_config.h" | 16 #include "build/build_config.h" |
17 #include "chrome/browser/crash_upload_list/crash_upload_list.h" | 17 #include "chrome/browser/crash_upload_list/crash_upload_list.h" |
18 #include "chrome/browser/metrics/chrome_metrics_service_accessor.h" | 18 #include "chrome/browser/metrics/chrome_metrics_service_accessor.h" |
19 #include "chrome/browser/profiles/profile.h" | 19 #include "chrome/browser/profiles/profile.h" |
20 #include "chrome/common/url_constants.h" | 20 #include "chrome/common/url_constants.h" |
| 21 #include "chrome/grit/browser_resources.h" |
21 #include "chrome/grit/chromium_strings.h" | 22 #include "chrome/grit/chromium_strings.h" |
22 #include "chrome/grit/generated_resources.h" | 23 #include "chrome/grit/generated_resources.h" |
23 #include "components/crash/core/browser/crashes_ui_util.h" | 24 #include "components/crash/core/browser/crashes_ui_util.h" |
| 25 #include "components/grit/components_resources.h" |
| 26 #include "components/grit/components_scaled_resources.h" |
| 27 #include "components/strings/grit/components_chromium_strings.h" |
| 28 #include "components/strings/grit/components_strings.h" |
24 #include "components/version_info/version_info.h" | 29 #include "components/version_info/version_info.h" |
25 #include "content/public/browser/web_contents.h" | 30 #include "content/public/browser/web_contents.h" |
26 #include "content/public/browser/web_ui.h" | 31 #include "content/public/browser/web_ui.h" |
27 #include "content/public/browser/web_ui_data_source.h" | 32 #include "content/public/browser/web_ui_data_source.h" |
28 #include "content/public/browser/web_ui_message_handler.h" | 33 #include "content/public/browser/web_ui_message_handler.h" |
29 #include "grit/browser_resources.h" | |
30 #include "grit/components_chromium_strings.h" | |
31 #include "grit/components_resources.h" | |
32 #include "grit/components_scaled_resources.h" | |
33 #include "grit/components_strings.h" | |
34 #include "ui/base/resource/resource_bundle.h" | 34 #include "ui/base/resource/resource_bundle.h" |
35 | 35 |
36 #if defined(OS_CHROMEOS) | 36 #if defined(OS_CHROMEOS) |
37 #include "chromeos/dbus/dbus_thread_manager.h" | 37 #include "chromeos/dbus/dbus_thread_manager.h" |
38 #include "chromeos/dbus/debug_daemon_client.h" | 38 #include "chromeos/dbus/debug_daemon_client.h" |
39 #endif | 39 #endif |
40 | 40 |
41 using content::WebContents; | 41 using content::WebContents; |
42 using content::WebUIMessageHandler; | 42 using content::WebUIMessageHandler; |
43 | 43 |
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
195 Profile* profile = Profile::FromWebUI(web_ui); | 195 Profile* profile = Profile::FromWebUI(web_ui); |
196 content::WebUIDataSource::Add(profile, CreateCrashesUIHTMLSource()); | 196 content::WebUIDataSource::Add(profile, CreateCrashesUIHTMLSource()); |
197 } | 197 } |
198 | 198 |
199 // static | 199 // static |
200 base::RefCountedMemory* CrashesUI::GetFaviconResourceBytes( | 200 base::RefCountedMemory* CrashesUI::GetFaviconResourceBytes( |
201 ui::ScaleFactor scale_factor) { | 201 ui::ScaleFactor scale_factor) { |
202 return ResourceBundle::GetSharedInstance().LoadDataResourceBytesForScale( | 202 return ResourceBundle::GetSharedInstance().LoadDataResourceBytesForScale( |
203 IDR_CRASH_SAD_FAVICON, scale_factor); | 203 IDR_CRASH_SAD_FAVICON, scale_factor); |
204 } | 204 } |
OLD | NEW |