OLD | NEW |
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 // 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 #if defined(OS_WIN) | 10 #if defined(OS_WIN) |
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
108 #include "webkit/fileapi/sandbox_mount_point_provider.h" | 108 #include "webkit/fileapi/sandbox_mount_point_provider.h" |
109 #include "webkit/glue/resource_type.h" | 109 #include "webkit/glue/resource_type.h" |
110 #include "webkit/plugins/plugin_switches.h" | 110 #include "webkit/plugins/plugin_switches.h" |
111 | 111 |
112 #if defined(OS_WIN) | 112 #if defined(OS_WIN) |
113 #include "base/synchronization/waitable_event.h" | 113 #include "base/synchronization/waitable_event.h" |
114 #include "content/common/font_cache_dispatcher_win.h" | 114 #include "content/common/font_cache_dispatcher_win.h" |
115 #endif | 115 #endif |
116 | 116 |
117 #if defined(ENABLE_INPUT_SPEECH) | 117 #if defined(ENABLE_INPUT_SPEECH) |
118 #include "content/browser/speech/speech_input_dispatcher_host.h" | 118 #include "content/browser/speech/speech_recognition_dispatcher_host.h" |
119 #endif | 119 #endif |
120 | 120 |
121 #include "third_party/skia/include/core/SkBitmap.h" | 121 #include "third_party/skia/include/core/SkBitmap.h" |
122 | 122 |
123 using content::BrowserContext; | 123 using content::BrowserContext; |
124 using content::BrowserMessageFilter; | 124 using content::BrowserMessageFilter; |
125 using content::BrowserThread; | 125 using content::BrowserThread; |
126 using content::ChildProcessHost; | 126 using content::ChildProcessHost; |
127 using content::ChildProcessHostImpl; | 127 using content::ChildProcessHostImpl; |
128 using content::UserMetricsAction; | 128 using content::UserMetricsAction; |
(...skipping 358 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
487 GetID(), browser_context->GetGeolocationPermissionContext())); | 487 GetID(), browser_context->GetGeolocationPermissionContext())); |
488 channel_->AddFilter(new GpuMessageFilter(GetID(), widget_helper_.get())); | 488 channel_->AddFilter(new GpuMessageFilter(GetID(), widget_helper_.get())); |
489 #if defined(ENABLE_WEBRTC) | 489 #if defined(ENABLE_WEBRTC) |
490 channel_->AddFilter(new media_stream::MediaStreamDispatcherHost( | 490 channel_->AddFilter(new media_stream::MediaStreamDispatcherHost( |
491 resource_context, GetID(), content::BrowserMainLoop::GetAudioManager())); | 491 resource_context, GetID(), content::BrowserMainLoop::GetAudioManager())); |
492 #endif | 492 #endif |
493 channel_->AddFilter(new PepperFileMessageFilter(GetID(), browser_context)); | 493 channel_->AddFilter(new PepperFileMessageFilter(GetID(), browser_context)); |
494 channel_->AddFilter(new PepperMessageFilter(PepperMessageFilter::RENDERER, | 494 channel_->AddFilter(new PepperMessageFilter(PepperMessageFilter::RENDERER, |
495 GetID(), resource_context)); | 495 GetID(), resource_context)); |
496 #if defined(ENABLE_INPUT_SPEECH) | 496 #if defined(ENABLE_INPUT_SPEECH) |
497 channel_->AddFilter(new speech_input::SpeechInputDispatcherHost( | 497 channel_->AddFilter(new speech::SpeechRecognitionDispatcherHost( |
498 GetID(), browser_context->GetRequestContext(), | 498 GetID(), browser_context->GetRequestContext(), |
499 browser_context->GetSpeechInputPreferences(), | 499 browser_context->GetSpeechRecognitionPreferences(), |
500 content::BrowserMainLoop::GetAudioManager())); | 500 content::BrowserMainLoop::GetAudioManager())); |
501 #endif | 501 #endif |
502 channel_->AddFilter(new FileAndBlobMessageFilter( | 502 channel_->AddFilter(new FileAndBlobMessageFilter( |
503 GetID(), | 503 GetID(), |
504 browser_context->GetRequestContext(), | 504 browser_context->GetRequestContext(), |
505 BrowserContext::GetFileSystemContext(browser_context), | 505 BrowserContext::GetFileSystemContext(browser_context), |
506 ChromeBlobStorageContext::GetFor(browser_context))); | 506 ChromeBlobStorageContext::GetFor(browser_context))); |
507 channel_->AddFilter(new device_orientation::MessageFilter()); | 507 channel_->AddFilter(new device_orientation::MessageFilter()); |
508 channel_->AddFilter(new FileUtilitiesMessageFilter(GetID())); | 508 channel_->AddFilter(new FileUtilitiesMessageFilter(GetID())); |
509 channel_->AddFilter(new MimeRegistryMessageFilter()); | 509 channel_->AddFilter(new MimeRegistryMessageFilter()); |
(...skipping 814 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1324 // Only honor the request if appropriate persmissions are granted. | 1324 // Only honor the request if appropriate persmissions are granted. |
1325 if (ChildProcessSecurityPolicyImpl::GetInstance()->CanReadFile(GetID(), | 1325 if (ChildProcessSecurityPolicyImpl::GetInstance()->CanReadFile(GetID(), |
1326 path)) | 1326 path)) |
1327 content::GetContentClient()->browser()->OpenItem(path); | 1327 content::GetContentClient()->browser()->OpenItem(path); |
1328 } | 1328 } |
1329 | 1329 |
1330 void RenderProcessHostImpl::OnSavedPageAsMHTML(int job_id, int64 data_size) { | 1330 void RenderProcessHostImpl::OnSavedPageAsMHTML(int job_id, int64 data_size) { |
1331 content::GetContentClient()->browser()->GetMHTMLGenerationManager()-> | 1331 content::GetContentClient()->browser()->GetMHTMLGenerationManager()-> |
1332 MHTMLGenerated(job_id, data_size); | 1332 MHTMLGenerated(job_id, data_size); |
1333 } | 1333 } |
OLD | NEW |