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

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

Issue 9924026: Browser side implementation of browser plugin (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Updated RenderProcessHostImpl Created 8 years, 8 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 | Annotate | Revision Log
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 // 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 24 matching lines...) Expand all
35 #include "base/stl_util.h" 35 #include "base/stl_util.h"
36 #include "base/string_util.h" 36 #include "base/string_util.h"
37 #include "base/sys_info.h" 37 #include "base/sys_info.h"
38 #include "base/threading/thread.h" 38 #include "base/threading/thread.h"
39 #include "base/threading/thread_restrictions.h" 39 #include "base/threading/thread_restrictions.h"
40 #include "base/tracked_objects.h" 40 #include "base/tracked_objects.h"
41 #include "content/browser/appcache/appcache_dispatcher_host.h" 41 #include "content/browser/appcache/appcache_dispatcher_host.h"
42 #include "content/browser/appcache/chrome_appcache_service.h" 42 #include "content/browser/appcache/chrome_appcache_service.h"
43 #include "content/browser/browser_main.h" 43 #include "content/browser/browser_main.h"
44 #include "content/browser/browser_main_loop.h" 44 #include "content/browser/browser_main_loop.h"
45 #include "content/browser/browser_plugin/renderer_host/browser_plugin_message_fi lter.h"
45 #include "content/browser/child_process_security_policy_impl.h" 46 #include "content/browser/child_process_security_policy_impl.h"
46 #include "content/browser/device_orientation/message_filter.h" 47 #include "content/browser/device_orientation/message_filter.h"
47 #include "content/browser/download/mhtml_generation_manager.h" 48 #include "content/browser/download/mhtml_generation_manager.h"
48 #include "content/browser/fileapi/chrome_blob_storage_context.h" 49 #include "content/browser/fileapi/chrome_blob_storage_context.h"
49 #include "content/browser/fileapi/fileapi_message_filter.h" 50 #include "content/browser/fileapi/fileapi_message_filter.h"
50 #include "content/browser/geolocation/geolocation_dispatcher_host.h" 51 #include "content/browser/geolocation/geolocation_dispatcher_host.h"
51 #include "content/browser/gpu/gpu_data_manager_impl.h" 52 #include "content/browser/gpu/gpu_data_manager_impl.h"
52 #include "content/browser/gpu/gpu_process_host.h" 53 #include "content/browser/gpu/gpu_process_host.h"
53 #include "content/browser/in_process_webkit/dom_storage_context_impl.h" 54 #include "content/browser/in_process_webkit/dom_storage_context_impl.h"
54 #include "content/browser/in_process_webkit/dom_storage_message_filter.h" 55 #include "content/browser/in_process_webkit/dom_storage_message_filter.h"
(...skipping 397 matching lines...) Expand 10 before | Expand all | Expand 10 after
452 content::GetContentClient()->browser()->GetMediaObserver(); 453 content::GetContentClient()->browser()->GetMediaObserver();
453 scoped_refptr<RenderMessageFilter> render_message_filter( 454 scoped_refptr<RenderMessageFilter> render_message_filter(
454 new RenderMessageFilter( 455 new RenderMessageFilter(
455 GetID(), 456 GetID(),
456 PluginServiceImpl::GetInstance(), 457 PluginServiceImpl::GetInstance(),
457 GetBrowserContext(), 458 GetBrowserContext(),
458 GetBrowserContext()->GetRequestContextForRenderProcess(GetID()), 459 GetBrowserContext()->GetRequestContextForRenderProcess(GetID()),
459 widget_helper_, 460 widget_helper_,
460 media_observer)); 461 media_observer));
461 channel_->AddFilter(render_message_filter); 462 channel_->AddFilter(render_message_filter);
463 scoped_refptr<BrowserPluginMessageFilter> browser_plugin_message_filter(
464 new BrowserPluginMessageFilter(GetID()));
465 channel_->AddFilter(browser_plugin_message_filter);
jam 2012/03/30 05:44:11 nit: we only create a local variable if we need to
Fady Samuel 2012/04/03 17:01:45 This has been deleted. BrowserPluginMessageFilter
462 content::BrowserContext* browser_context = GetBrowserContext(); 466 content::BrowserContext* browser_context = GetBrowserContext();
463 content::ResourceContext* resource_context = 467 content::ResourceContext* resource_context =
464 browser_context->GetResourceContext(); 468 browser_context->GetResourceContext();
465 469
466 ResourceMessageFilter* resource_message_filter = new ResourceMessageFilter( 470 ResourceMessageFilter* resource_message_filter = new ResourceMessageFilter(
467 GetID(), content::PROCESS_TYPE_RENDERER, resource_context, 471 GetID(), content::PROCESS_TYPE_RENDERER, resource_context,
468 new RendererURLRequestContextSelector(browser_context, GetID())); 472 new RendererURLRequestContextSelector(browser_context, GetID()));
469 473
470 channel_->AddFilter(resource_message_filter); 474 channel_->AddFilter(resource_message_filter);
471 #if !defined(OS_ANDROID) 475 #if !defined(OS_ANDROID)
(...skipping 870 matching lines...) Expand 10 before | Expand all | Expand 10 after
1342 void RenderProcessHostImpl::OnRevealFolderInOS(const FilePath& path) { 1346 void RenderProcessHostImpl::OnRevealFolderInOS(const FilePath& path) {
1343 // Only honor the request if appropriate persmissions are granted. 1347 // Only honor the request if appropriate persmissions are granted.
1344 if (ChildProcessSecurityPolicyImpl::GetInstance()->CanReadFile(GetID(), 1348 if (ChildProcessSecurityPolicyImpl::GetInstance()->CanReadFile(GetID(),
1345 path)) 1349 path))
1346 content::GetContentClient()->browser()->OpenItem(path); 1350 content::GetContentClient()->browser()->OpenItem(path);
1347 } 1351 }
1348 1352
1349 void RenderProcessHostImpl::OnSavedPageAsMHTML(int job_id, int64 data_size) { 1353 void RenderProcessHostImpl::OnSavedPageAsMHTML(int job_id, int64 data_size) {
1350 MHTMLGenerationManager::GetInstance()->MHTMLGenerated(job_id, data_size); 1354 MHTMLGenerationManager::GetInstance()->MHTMLGenerated(job_id, data_size);
1351 } 1355 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698