Chromium Code Reviews| 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/chrome_content_browser_client.h" | 5 #include "chrome/browser/chrome_content_browser_client.h" |
| 6 | 6 |
| 7 #include <map> | 7 #include <map> |
| 8 #include <set> | 8 #include <set> |
| 9 #include <utility> | 9 #include <utility> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 132 #include "components/error_page/common/error_page_switches.h" | 132 #include "components/error_page/common/error_page_switches.h" |
| 133 #include "components/google/core/browser/google_util.h" | 133 #include "components/google/core/browser/google_util.h" |
| 134 #include "components/metrics/call_stack_profile_collector.h" | 134 #include "components/metrics/call_stack_profile_collector.h" |
| 135 #include "components/metrics/client_info.h" | 135 #include "components/metrics/client_info.h" |
| 136 #include "components/nacl/common/nacl_constants.h" | 136 #include "components/nacl/common/nacl_constants.h" |
| 137 #include "components/net_log/chrome_net_log.h" | 137 #include "components/net_log/chrome_net_log.h" |
| 138 #include "components/password_manager/content/browser/content_password_manager_d river_factory.h" | 138 #include "components/password_manager/content/browser/content_password_manager_d river_factory.h" |
| 139 #include "components/pref_registry/pref_registry_syncable.h" | 139 #include "components/pref_registry/pref_registry_syncable.h" |
| 140 #include "components/prefs/pref_service.h" | 140 #include "components/prefs/pref_service.h" |
| 141 #include "components/prefs/scoped_user_pref_update.h" | 141 #include "components/prefs/scoped_user_pref_update.h" |
| 142 #include "components/printing/service/public/interfaces/pdf_compositor.mojom.h" | |
|
Lei Zhang
2017/04/22 00:12:26
Also ifdef'd?
Wei Li
2017/04/27 05:34:16
Done.
| |
| 142 #include "components/rappor/public/rappor_utils.h" | 143 #include "components/rappor/public/rappor_utils.h" |
| 143 #include "components/rappor/rappor_recorder_impl.h" | 144 #include "components/rappor/rappor_recorder_impl.h" |
| 144 #include "components/rappor/rappor_service_impl.h" | 145 #include "components/rappor/rappor_service_impl.h" |
| 145 #include "components/safe_browsing_db/safe_browsing_prefs.h" | 146 #include "components/safe_browsing_db/safe_browsing_prefs.h" |
| 146 #include "components/security_interstitials/core/ssl_error_ui.h" | 147 #include "components/security_interstitials/core/ssl_error_ui.h" |
| 147 #include "components/signin/core/common/profile_management_switches.h" | 148 #include "components/signin/core/common/profile_management_switches.h" |
| 148 #include "components/spellcheck/spellcheck_build_features.h" | 149 #include "components/spellcheck/spellcheck_build_features.h" |
| 149 #include "components/startup_metric_utils/browser/startup_metric_host_impl.h" | 150 #include "components/startup_metric_utils/browser/startup_metric_host_impl.h" |
| 150 #include "components/subresource_filter/content/browser/content_subresource_filt er_driver_factory.h" | 151 #include "components/subresource_filter/content/browser/content_subresource_filt er_driver_factory.h" |
| 151 #include "components/subresource_filter/content/browser/content_subresource_filt er_throttle_manager.h" | 152 #include "components/subresource_filter/content/browser/content_subresource_filt er_throttle_manager.h" |
| (...skipping 3146 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 3298 } | 3299 } |
| 3299 #endif // OS_CHROMEOS | 3300 #endif // OS_CHROMEOS |
| 3300 } | 3301 } |
| 3301 | 3302 |
| 3302 void ChromeContentBrowserClient::RegisterOutOfProcessServices( | 3303 void ChromeContentBrowserClient::RegisterOutOfProcessServices( |
| 3303 OutOfProcessServiceMap* services) { | 3304 OutOfProcessServiceMap* services) { |
| 3304 #if defined(ENABLE_MOJO_MEDIA_IN_UTILITY_PROCESS) | 3305 #if defined(ENABLE_MOJO_MEDIA_IN_UTILITY_PROCESS) |
| 3305 services->insert(std::make_pair("media", | 3306 services->insert(std::make_pair("media", |
| 3306 base::ASCIIToUTF16("Media Service"))); | 3307 base::ASCIIToUTF16("Media Service"))); |
| 3307 #endif | 3308 #endif |
| 3309 | |
| 3310 #if BUILDFLAG(ENABLE_PRINTING) | |
| 3311 services->insert( | |
| 3312 std::make_pair(printing::mojom::kServiceName, | |
| 3313 base::ASCIIToUTF16("PDF Compositor Service"))); | |
| 3314 #endif | |
| 3308 } | 3315 } |
| 3309 | 3316 |
| 3310 std::unique_ptr<base::Value> | 3317 std::unique_ptr<base::Value> |
| 3311 ChromeContentBrowserClient::GetServiceManifestOverlay(base::StringPiece name) { | 3318 ChromeContentBrowserClient::GetServiceManifestOverlay(base::StringPiece name) { |
| 3312 ResourceBundle& rb = ResourceBundle::GetSharedInstance(); | 3319 ResourceBundle& rb = ResourceBundle::GetSharedInstance(); |
| 3313 int id = -1; | 3320 int id = -1; |
| 3314 if (name == content::mojom::kBrowserServiceName) | 3321 if (name == content::mojom::kBrowserServiceName) |
| 3315 id = IDR_CHROME_CONTENT_BROWSER_MANIFEST_OVERLAY; | 3322 id = IDR_CHROME_CONTENT_BROWSER_MANIFEST_OVERLAY; |
| 3316 else if (name == content::mojom::kGpuServiceName) | 3323 else if (name == content::mojom::kGpuServiceName) |
| 3317 id = IDR_CHROME_CONTENT_GPU_MANIFEST_OVERLAY; | 3324 id = IDR_CHROME_CONTENT_GPU_MANIFEST_OVERLAY; |
| (...skipping 328 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 3646 RedirectNonUINonIOBrowserThreadsToTaskScheduler() { | 3653 RedirectNonUINonIOBrowserThreadsToTaskScheduler() { |
| 3647 return variations::GetVariationParamValue( | 3654 return variations::GetVariationParamValue( |
| 3648 "BrowserScheduler", "RedirectNonUINonIOBrowserThreads") == "true"; | 3655 "BrowserScheduler", "RedirectNonUINonIOBrowserThreads") == "true"; |
| 3649 } | 3656 } |
| 3650 | 3657 |
| 3651 // static | 3658 // static |
| 3652 void ChromeContentBrowserClient::SetDefaultQuotaSettingsForTesting( | 3659 void ChromeContentBrowserClient::SetDefaultQuotaSettingsForTesting( |
| 3653 const storage::QuotaSettings* settings) { | 3660 const storage::QuotaSettings* settings) { |
| 3654 g_default_quota_settings = settings; | 3661 g_default_quota_settings = settings; |
| 3655 } | 3662 } |
| OLD | NEW |