| Index: content/browser/tab_contents/render_view_host_manager.cc
|
| diff --git a/content/browser/tab_contents/render_view_host_manager.cc b/content/browser/tab_contents/render_view_host_manager.cc
|
| index ee56978db31a653a8190ed6b70c5905dc8358597..728c8a9fe2f77d86794e88aadc08736c99947b02 100644
|
| --- a/content/browser/tab_contents/render_view_host_manager.cc
|
| +++ b/content/browser/tab_contents/render_view_host_manager.cc
|
| @@ -19,8 +19,9 @@
|
| #include "content/browser/tab_contents/navigation_controller.h"
|
| #include "content/browser/tab_contents/navigation_entry.h"
|
| #include "content/browser/tab_contents/tab_contents_view.h"
|
| +#include "content/browser/webui/content_web_ui_client.h"
|
| #include "content/browser/webui/web_ui.h"
|
| -#include "content/browser/webui/web_ui_factory.h"
|
| +#include "content/common/content_client.h"
|
| #include "content/common/notification_service.h"
|
| #include "content/common/notification_type.h"
|
| #include "content/common/view_messages.h"
|
| @@ -301,13 +302,15 @@ bool RenderViewHostManager::ShouldSwapProcessesForNavigation(
|
| const GURL& current_url = (cur_entry) ? cur_entry->url() :
|
| render_view_host_->site_instance()->site();
|
| Profile* profile = delegate_->GetControllerForRenderManager().profile();
|
| - if (WebUIFactory::UseWebUIForURL(profile, current_url)) {
|
| + const content::ContentWebUIClient* web_ui_client =
|
| + content::GetContentClient()->web_ui();
|
| + if (web_ui_client->UseWebUIForURL(profile, current_url)) {
|
| // Force swap if it's not an acceptable URL for Web UI.
|
| - if (!WebUIFactory::IsURLAcceptableForWebUI(profile, new_entry->url()))
|
| + if (!web_ui_client->IsURLAcceptableForWebUI(profile, new_entry->url()))
|
| return true;
|
| } else {
|
| // Force swap if it's a Web UI URL.
|
| - if (WebUIFactory::UseWebUIForURL(profile, new_entry->url()))
|
| + if (web_ui_client->UseWebUIForURL(profile, new_entry->url()))
|
| return true;
|
| }
|
|
|
| @@ -384,8 +387,10 @@ SiteInstance* RenderViewHostManager::GetSiteInstanceForEntry(
|
| // want to use the curr_instance if it has no site, since it will have a
|
| // RenderProcessHost of TYPE_NORMAL. Create a new SiteInstance for this
|
| // URL instead (with the correct process type).
|
| - if (WebUIFactory::UseWebUIForURL(profile, dest_url))
|
| + if (content::GetContentClient()->web_ui()->
|
| + UseWebUIForURL(profile, dest_url)) {
|
| return SiteInstance::CreateSiteInstanceForURL(profile, dest_url);
|
| + }
|
|
|
| // Normally the "site" on the SiteInstance is set lazily when the load
|
| // actually commits. This is to support better process sharing in case
|
|
|