Chromium Code Reviews| Index: chrome/browser/ui/browser_navigator.cc |
| diff --git a/chrome/browser/ui/browser_navigator.cc b/chrome/browser/ui/browser_navigator.cc |
| index 1a7e8063626468d6f4ecb99c13cc336d3efca219..507b74a059b8c3d64e34a44a4f7db62a6e60fbe6 100644 |
| --- a/chrome/browser/ui/browser_navigator.cc |
| +++ b/chrome/browser/ui/browser_navigator.cc |
| @@ -354,11 +354,16 @@ class ScopedTargetContentsOwner { |
| content::WebContents* CreateTargetContents(const chrome::NavigateParams& params, |
| const GURL& url) { |
| - WebContents::CreateParams create_params( |
| - params.browser->profile(), |
| - params.source_site_instance |
| - ? params.source_site_instance |
| - : tab_util::GetSiteInstanceForNewTab(params.browser->profile(), url)); |
| + WebContents::CreateParams create_params(params.browser->profile()); |
| + if (params.use_new_renderer_for_new_contents) { |
| + create_params.site_instance = nullptr; |
|
Charlie Reis
2017/04/19 20:11:11
I missed this before, but is there a reason we're
Łukasz Anforowicz
2017/04/20 01:11:29
Thanks for catching this - you're right this shoul
|
| + } else if (params.source_site_instance) { |
| + create_params.site_instance = params.source_site_instance; |
| + } else { |
| + create_params.site_instance = |
| + tab_util::GetSiteInstanceForNewTab(params.browser->profile(), url); |
| + } |
| + |
| create_params.main_frame_name = params.frame_name; |
| if (params.source_contents) { |
| create_params.initial_size = |