Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(486)

Side by Side Diff: chrome/renderer/chrome_content_renderer_client.cc

Issue 2960703003: Add a feature flag for network service and about:flags entry for it. (Closed)
Patch Set: merge Created 3 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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/renderer/chrome_content_renderer_client.h" 5 #include "chrome/renderer/chrome_content_renderer_client.h"
6 6
7 #include <memory> 7 #include <memory>
8 #include <utility> 8 #include <utility>
9 9
10 #include "base/bind.h" 10 #include "base/bind.h"
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
83 #include "components/signin/core/common/profile_management_switches.h" 83 #include "components/signin/core/common/profile_management_switches.h"
84 #include "components/spellcheck/spellcheck_build_features.h" 84 #include "components/spellcheck/spellcheck_build_features.h"
85 #include "components/startup_metric_utils/common/startup_metric.mojom.h" 85 #include "components/startup_metric_utils/common/startup_metric.mojom.h"
86 #include "components/subresource_filter/content/renderer/subresource_filter_agen t.h" 86 #include "components/subresource_filter/content/renderer/subresource_filter_agen t.h"
87 #include "components/subresource_filter/content/renderer/unverified_ruleset_deal er.h" 87 #include "components/subresource_filter/content/renderer/unverified_ruleset_deal er.h"
88 #include "components/task_scheduler_util/renderer/initialization.h" 88 #include "components/task_scheduler_util/renderer/initialization.h"
89 #include "components/version_info/version_info.h" 89 #include "components/version_info/version_info.h"
90 #include "components/visitedlink/renderer/visitedlink_slave.h" 90 #include "components/visitedlink/renderer/visitedlink_slave.h"
91 #include "components/web_cache/renderer/web_cache_impl.h" 91 #include "components/web_cache/renderer/web_cache_impl.h"
92 #include "content/public/common/content_constants.h" 92 #include "content/public/common/content_constants.h"
93 #include "content/public/common/content_features.h"
93 #include "content/public/common/content_switches.h" 94 #include "content/public/common/content_switches.h"
94 #include "content/public/common/service_names.mojom.h" 95 #include "content/public/common/service_names.mojom.h"
95 #include "content/public/common/url_constants.h" 96 #include "content/public/common/url_constants.h"
96 #include "content/public/renderer/plugin_instance_throttler.h" 97 #include "content/public/renderer/plugin_instance_throttler.h"
97 #include "content/public/renderer/render_frame.h" 98 #include "content/public/renderer/render_frame.h"
98 #include "content/public/renderer/render_frame_visitor.h" 99 #include "content/public/renderer/render_frame_visitor.h"
99 #include "content/public/renderer/render_thread.h" 100 #include "content/public/renderer/render_thread.h"
100 #include "content/public/renderer/render_view.h" 101 #include "content/public/renderer/render_view.h"
101 #include "extensions/common/constants.h" 102 #include "extensions/common/constants.h"
102 #include "extensions/features/features.h" 103 #include "extensions/features/features.h"
(...skipping 1508 matching lines...) Expand 10 before | Expand all | Expand 10 after
1611 1612
1612 std::unique_ptr<base::TaskScheduler::InitParams> 1613 std::unique_ptr<base::TaskScheduler::InitParams>
1613 ChromeContentRendererClient::GetTaskSchedulerInitParams() { 1614 ChromeContentRendererClient::GetTaskSchedulerInitParams() {
1614 return task_scheduler_util:: 1615 return task_scheduler_util::
1615 GetRendererTaskSchedulerInitParamsFromCommandLine(); 1616 GetRendererTaskSchedulerInitParamsFromCommandLine();
1616 } 1617 }
1617 1618
1618 bool ChromeContentRendererClient::UsingSafeBrowsingMojoService() { 1619 bool ChromeContentRendererClient::UsingSafeBrowsingMojoService() {
1619 if (safe_browsing_) 1620 if (safe_browsing_)
1620 return true; 1621 return true;
1621 if (!base::CommandLine::ForCurrentProcess()->HasSwitch( 1622 if (!base::FeatureList::IsEnabled(features::kNetworkService))
1622 switches::kEnableNetworkService)) {
1623 return false; 1623 return false;
1624 }
1625 RenderThread::Get()->GetConnector()->BindInterface( 1624 RenderThread::Get()->GetConnector()->BindInterface(
1626 content::mojom::kBrowserServiceName, &safe_browsing_); 1625 content::mojom::kBrowserServiceName, &safe_browsing_);
1627 return true; 1626 return true;
1628 } 1627 }
OLDNEW
« no previous file with comments | « chrome/browser/safe_browsing/safe_browsing_service_browsertest.cc ('k') | content/app/content_main_runner.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698