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/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 515 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
526 channel_->AddFilter(new content::P2PSocketDispatcherHost( | 526 channel_->AddFilter(new content::P2PSocketDispatcherHost( |
527 &GetBrowserContext()->GetResourceContext())); | 527 &GetBrowserContext()->GetResourceContext())); |
528 #endif | 528 #endif |
529 | 529 |
530 channel_->AddFilter(new TraceMessageFilter()); | 530 channel_->AddFilter(new TraceMessageFilter()); |
531 channel_->AddFilter(new ResolveProxyMsgHelper( | 531 channel_->AddFilter(new ResolveProxyMsgHelper( |
532 GetBrowserContext()->GetRequestContextForRenderProcess(GetID()))); | 532 GetBrowserContext()->GetRequestContextForRenderProcess(GetID()))); |
533 channel_->AddFilter(new QuotaDispatcherHost( | 533 channel_->AddFilter(new QuotaDispatcherHost( |
534 GetID(), GetBrowserContext()->GetQuotaManager(), | 534 GetID(), GetBrowserContext()->GetQuotaManager(), |
535 content::GetContentClient()->browser()->CreateQuotaPermissionContext())); | 535 content::GetContentClient()->browser()->CreateQuotaPermissionContext())); |
536 channel_->AddFilter(new GamepadBrowserMessageFilter); | 536 channel_->AddFilter(new content::GamepadBrowserMessageFilter(this)); |
537 } | 537 } |
538 | 538 |
539 int RenderProcessHostImpl::GetNextRoutingID() { | 539 int RenderProcessHostImpl::GetNextRoutingID() { |
540 return widget_helper_->GetNextRoutingID(); | 540 return widget_helper_->GetNextRoutingID(); |
541 } | 541 } |
542 | 542 |
543 void RenderProcessHostImpl::UpdateAndSendMaxPageID(int32 page_id) { | 543 void RenderProcessHostImpl::UpdateAndSendMaxPageID(int32 page_id) { |
544 if (page_id > max_page_id_) | 544 if (page_id > max_page_id_) |
545 Send(new ViewMsg_SetNextPageID(page_id + 1)); | 545 Send(new ViewMsg_SetNextPageID(page_id + 1)); |
546 UpdateMaxPageID(page_id); | 546 UpdateMaxPageID(page_id); |
(...skipping 764 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1311 void RenderProcessHostImpl::OnRevealFolderInOS(const FilePath& path) { | 1311 void RenderProcessHostImpl::OnRevealFolderInOS(const FilePath& path) { |
1312 // Only honor the request if appropriate persmissions are granted. | 1312 // Only honor the request if appropriate persmissions are granted. |
1313 if (ChildProcessSecurityPolicy::GetInstance()->CanReadFile(GetID(), path)) | 1313 if (ChildProcessSecurityPolicy::GetInstance()->CanReadFile(GetID(), path)) |
1314 content::GetContentClient()->browser()->OpenItem(path); | 1314 content::GetContentClient()->browser()->OpenItem(path); |
1315 } | 1315 } |
1316 | 1316 |
1317 void RenderProcessHostImpl::OnSavedPageAsMHTML(int job_id, int64 data_size) { | 1317 void RenderProcessHostImpl::OnSavedPageAsMHTML(int job_id, int64 data_size) { |
1318 content::GetContentClient()->browser()->GetMHTMLGenerationManager()-> | 1318 content::GetContentClient()->browser()->GetMHTMLGenerationManager()-> |
1319 MHTMLGenerated(job_id, data_size); | 1319 MHTMLGenerated(job_id, data_size); |
1320 } | 1320 } |
OLD | NEW |