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

Side by Side Diff: content/browser/renderer_host/render_process_host_impl.cc

Issue 1481583002: Narrow the interface to ResourceMessageFilter::GetContexts() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Clarify when |origin_pid| argument is used. Created 5 years 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 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 // Represents the browser side of the browser <--> renderer communication 5 // Represents the browser side of the browser <--> renderer communication
6 // channel. There will be one RenderProcessHost per renderer process. 6 // channel. There will be one RenderProcessHost per renderer process.
7 7
8 #include "content/browser/renderer_host/render_process_host_impl.h" 8 #include "content/browser/renderer_host/render_process_host_impl.h"
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 247 matching lines...) Expand 10 before | Expand all | Expand 10 after
258 // specific needs for caching. 258 // specific needs for caching.
259 if (resource_type == RESOURCE_TYPE_MEDIA) 259 if (resource_type == RESOURCE_TYPE_MEDIA)
260 return media_request_context->GetURLRequestContext(); 260 return media_request_context->GetURLRequestContext();
261 return request_context->GetURLRequestContext(); 261 return request_context->GetURLRequestContext();
262 } 262 }
263 263
264 void GetContexts( 264 void GetContexts(
265 ResourceContext* resource_context, 265 ResourceContext* resource_context,
266 scoped_refptr<net::URLRequestContextGetter> request_context, 266 scoped_refptr<net::URLRequestContextGetter> request_context,
267 scoped_refptr<net::URLRequestContextGetter> media_request_context, 267 scoped_refptr<net::URLRequestContextGetter> media_request_context,
268 const ResourceHostMsg_Request& request, 268 ResourceType resource_type,
269 int origin_pid,
269 ResourceContext** resource_context_out, 270 ResourceContext** resource_context_out,
270 net::URLRequestContext** request_context_out) { 271 net::URLRequestContext** request_context_out) {
271 *resource_context_out = resource_context; 272 *resource_context_out = resource_context;
272 *request_context_out = GetRequestContext( 273 *request_context_out =
273 request_context, media_request_context, request.resource_type); 274 GetRequestContext(request_context, media_request_context, resource_type);
274 } 275 }
275 276
276 #if defined(ENABLE_WEBRTC) 277 #if defined(ENABLE_WEBRTC)
277 278
278 // Allow us to only run the trial in the first renderer. 279 // Allow us to only run the trial in the first renderer.
279 bool has_done_stun_trials = false; 280 bool has_done_stun_trials = false;
280 281
281 // Creates a file used for diagnostic echo canceller recordings for handing 282 // Creates a file used for diagnostic echo canceller recordings for handing
282 // over to the renderer. 283 // over to the renderer.
283 IPC::PlatformFileForTransit CreateAecDumpFileForProcess( 284 IPC::PlatformFileForTransit CreateAecDumpFileForProcess(
(...skipping 2335 matching lines...) Expand 10 before | Expand all | Expand 10 after
2619 void RenderProcessHostImpl::GetAudioOutputControllers( 2620 void RenderProcessHostImpl::GetAudioOutputControllers(
2620 const GetAudioOutputControllersCallback& callback) const { 2621 const GetAudioOutputControllersCallback& callback) const {
2621 audio_renderer_host()->GetOutputControllers(callback); 2622 audio_renderer_host()->GetOutputControllers(callback);
2622 } 2623 }
2623 2624
2624 BluetoothDispatcherHost* RenderProcessHostImpl::GetBluetoothDispatcherHost() { 2625 BluetoothDispatcherHost* RenderProcessHostImpl::GetBluetoothDispatcherHost() {
2625 return bluetooth_dispatcher_host_.get(); 2626 return bluetooth_dispatcher_host_.get();
2626 } 2627 }
2627 2628
2628 } // namespace content 2629 } // namespace content
OLDNEW
« content/browser/loader/resource_message_filter.h ('K') | « content/browser/plugin_process_host.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698