| Index: content/browser/renderer_host/render_process_host_impl.cc
|
| ===================================================================
|
| --- content/browser/renderer_host/render_process_host_impl.cc (revision 175970)
|
| +++ content/browser/renderer_host/render_process_host_impl.cc (working copy)
|
| @@ -83,6 +83,7 @@
|
| #include "content/browser/speech/input_tag_speech_dispatcher_host.h"
|
| #include "content/browser/speech/speech_recognition_dispatcher_host.h"
|
| #include "content/browser/trace_message_filter.h"
|
| +#include "content/browser/webui/web_ui_controller_factory_registry.h"
|
| #include "content/browser/worker_host/worker_storage_partition.h"
|
| #include "content/browser/worker_host/worker_message_filter.h"
|
| #include "content/common/child_process_host_impl.h"
|
| @@ -97,7 +98,6 @@
|
| #include "content/public/browser/render_process_host_factory.h"
|
| #include "content/public/browser/resource_context.h"
|
| #include "content/public/browser/user_metrics.h"
|
| -#include "content/public/browser/web_ui_controller_factory.h"
|
| #include "content/public/common/content_constants.h"
|
| #include "content/public/common/content_switches.h"
|
| #include "content/public/common/process_type.h"
|
| @@ -1268,12 +1268,10 @@
|
| if (!host->IsGuest() && site_url.SchemeIs(chrome::kGuestScheme))
|
| return false;
|
|
|
| - WebUIControllerFactory* factory =
|
| - GetContentClient()->browser()->GetWebUIControllerFactory();
|
| - if (factory &&
|
| - ChildProcessSecurityPolicyImpl::GetInstance()->HasWebUIBindings(
|
| + if (ChildProcessSecurityPolicyImpl::GetInstance()->HasWebUIBindings(
|
| host->GetID()) !=
|
| - factory->UseWebUIBindingsForURL(browser_context, site_url)) {
|
| + WebUIControllerFactoryRegistry::GetInstance()->UseWebUIBindingsForURL(
|
| + browser_context, site_url)) {
|
| return false;
|
| }
|
|
|
| @@ -1389,10 +1387,8 @@
|
| }
|
|
|
| // DevTools pages have WebUI type but should not reuse the same host.
|
| - WebUIControllerFactory* factory =
|
| - GetContentClient()->browser()->GetWebUIControllerFactory();
|
| - if (factory &&
|
| - factory->UseWebUIForURL(browser_context, url) &&
|
| + if (WebUIControllerFactoryRegistry::GetInstance()->UseWebUIForURL(
|
| + browser_context, url) &&
|
| !url.SchemeIs(chrome::kChromeDevToolsScheme)) {
|
| return true;
|
| }
|
|
|