OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/browser_render_process_host.h" | 8 #include "content/browser/renderer_host/browser_render_process_host.h" |
9 | 9 |
10 #include <algorithm> | 10 #include <algorithm> |
(...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
395 | 395 |
396 channel_->AddFilter( | 396 channel_->AddFilter( |
397 new WorkerMessageFilter( | 397 new WorkerMessageFilter( |
398 id(), | 398 id(), |
399 &browser_context()->GetResourceContext(), | 399 &browser_context()->GetResourceContext(), |
400 content::GetContentClient()->browser()->GetResourceDispatcherHost(), | 400 content::GetContentClient()->browser()->GetResourceDispatcherHost(), |
401 NewCallbackWithReturnValue( | 401 NewCallbackWithReturnValue( |
402 widget_helper_.get(), &RenderWidgetHelper::GetNextRoutingID))); | 402 widget_helper_.get(), &RenderWidgetHelper::GetNextRoutingID))); |
403 | 403 |
404 #if defined(ENABLE_P2P_APIS) | 404 #if defined(ENABLE_P2P_APIS) |
405 channel_->AddFilter(new P2PSocketDispatcherHost()); | 405 channel_->AddFilter(new P2PSocketDispatcherHost( |
| 406 &browser_context()->GetResourceContext())); |
406 #endif | 407 #endif |
407 | 408 |
408 channel_->AddFilter(new TraceMessageFilter()); | 409 channel_->AddFilter(new TraceMessageFilter()); |
409 channel_->AddFilter(new ResolveProxyMsgHelper(NULL)); | 410 channel_->AddFilter(new ResolveProxyMsgHelper(NULL)); |
410 channel_->AddFilter(new QuotaDispatcherHost( | 411 channel_->AddFilter(new QuotaDispatcherHost( |
411 id(), browser_context()->GetQuotaManager(), | 412 id(), browser_context()->GetQuotaManager(), |
412 content::GetContentClient()->browser()->CreateQuotaPermissionContext())); | 413 content::GetContentClient()->browser()->CreateQuotaPermissionContext())); |
413 } | 414 } |
414 | 415 |
415 int BrowserRenderProcessHost::GetNextRoutingID() { | 416 int BrowserRenderProcessHost::GetNextRoutingID() { |
(...skipping 504 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
920 void BrowserRenderProcessHost::OnRevealFolderInOS(const FilePath& path) { | 921 void BrowserRenderProcessHost::OnRevealFolderInOS(const FilePath& path) { |
921 // Only honor the request if appropriate persmissions are granted. | 922 // Only honor the request if appropriate persmissions are granted. |
922 if (ChildProcessSecurityPolicy::GetInstance()->CanReadFile(id(), path)) | 923 if (ChildProcessSecurityPolicy::GetInstance()->CanReadFile(id(), path)) |
923 content::GetContentClient()->browser()->RevealFolderInOS(path); | 924 content::GetContentClient()->browser()->RevealFolderInOS(path); |
924 } | 925 } |
925 | 926 |
926 void BrowserRenderProcessHost::OnSavedPageAsMHTML(int job_id, bool success) { | 927 void BrowserRenderProcessHost::OnSavedPageAsMHTML(int job_id, bool success) { |
927 content::GetContentClient()->browser()->GetMHTMLGenerationManager()-> | 928 content::GetContentClient()->browser()->GetMHTMLGenerationManager()-> |
928 MHTMLGenerated(job_id, success); | 929 MHTMLGenerated(job_id, success); |
929 } | 930 } |
OLD | NEW |