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

Side by Side Diff: chrome/browser/chrome_content_browser_client.cc

Issue 2052613003: Speculatively launch Service Workers on mouse/touch events. [3/5] (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove unnecessary includes Created 4 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
« no previous file with comments | « no previous file | chrome/browser/renderer_host/chrome_render_message_filter.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/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 939 matching lines...) Expand 10 before | Expand all | Expand 10 after
950 return chrome::CreateWebContentsViewDelegate(web_contents); 950 return chrome::CreateWebContentsViewDelegate(web_contents);
951 } 951 }
952 952
953 void ChromeContentBrowserClient::RenderProcessWillLaunch( 953 void ChromeContentBrowserClient::RenderProcessWillLaunch(
954 content::RenderProcessHost* host) { 954 content::RenderProcessHost* host) {
955 int id = host->GetID(); 955 int id = host->GetID();
956 Profile* profile = Profile::FromBrowserContext(host->GetBrowserContext()); 956 Profile* profile = Profile::FromBrowserContext(host->GetBrowserContext());
957 net::URLRequestContextGetter* context = 957 net::URLRequestContextGetter* context =
958 host->GetStoragePartition()->GetURLRequestContext(); 958 host->GetStoragePartition()->GetURLRequestContext();
959 959
960 host->AddFilter(new ChromeRenderMessageFilter(id, profile)); 960 host->AddFilter(new ChromeRenderMessageFilter(
961 id, profile, host->GetStoragePartition()->GetServiceWorkerContext()));
961 #if defined(ENABLE_EXTENSIONS) 962 #if defined(ENABLE_EXTENSIONS)
962 host->AddFilter(new cast::CastTransportHostFilter); 963 host->AddFilter(new cast::CastTransportHostFilter);
963 #endif 964 #endif
964 #if defined(ENABLE_PRINTING) 965 #if defined(ENABLE_PRINTING)
965 host->AddFilter(new printing::PrintingMessageFilter(id, profile)); 966 host->AddFilter(new printing::PrintingMessageFilter(id, profile));
966 #endif 967 #endif
967 host->AddOwnedInterface( 968 host->AddOwnedInterface(
968 base::MakeUnique<SearchProviderInstallStateImpl>(id, profile), 969 base::MakeUnique<SearchProviderInstallStateImpl>(id, profile),
969 &SearchProviderInstallStateImpl::Bind, 970 &SearchProviderInstallStateImpl::Bind,
970 content::BrowserThread::GetTaskRunnerForThread( 971 content::BrowserThread::GetTaskRunnerForThread(
(...skipping 2085 matching lines...) Expand 10 before | Expand all | Expand 10 after
3056 if (channel <= kMaxDisableEncryptionChannel) { 3057 if (channel <= kMaxDisableEncryptionChannel) {
3057 static const char* const kWebRtcDevSwitchNames[] = { 3058 static const char* const kWebRtcDevSwitchNames[] = {
3058 switches::kDisableWebRtcEncryption, 3059 switches::kDisableWebRtcEncryption,
3059 }; 3060 };
3060 to_command_line->CopySwitchesFrom(from_command_line, 3061 to_command_line->CopySwitchesFrom(from_command_line,
3061 kWebRtcDevSwitchNames, 3062 kWebRtcDevSwitchNames,
3062 arraysize(kWebRtcDevSwitchNames)); 3063 arraysize(kWebRtcDevSwitchNames));
3063 } 3064 }
3064 } 3065 }
3065 #endif // defined(ENABLE_WEBRTC) 3066 #endif // defined(ENABLE_WEBRTC)
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/renderer_host/chrome_render_message_filter.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698