| 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 #include "chrome/browser/chrome_content_browser_client.h" | 5 #include "chrome/browser/chrome_content_browser_client.h" |
| 6 | 6 |
| 7 #include <map> | 7 #include <map> |
| 8 #include <set> | 8 #include <set> |
| 9 #include <utility> | 9 #include <utility> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 1430 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1441 #if BUILDFLAG(ENABLE_EXTENSIONS) | 1441 #if BUILDFLAG(ENABLE_EXTENSIONS) |
| 1442 ChromeContentBrowserClientExtensionsPart::OverrideNavigationParams( | 1442 ChromeContentBrowserClientExtensionsPart::OverrideNavigationParams( |
| 1443 site_instance, transition, is_renderer_initiated, referrer); | 1443 site_instance, transition, is_renderer_initiated, referrer); |
| 1444 #endif | 1444 #endif |
| 1445 } | 1445 } |
| 1446 | 1446 |
| 1447 bool ChromeContentBrowserClient:: | 1447 bool ChromeContentBrowserClient:: |
| 1448 ShouldFrameShareParentSiteInstanceDespiteTopDocumentIsolation( | 1448 ShouldFrameShareParentSiteInstanceDespiteTopDocumentIsolation( |
| 1449 const GURL& url, | 1449 const GURL& url, |
| 1450 content::SiteInstance* parent_site_instance) { | 1450 content::SiteInstance* parent_site_instance) { |
| 1451 return IsNTPSiteInstance(parent_site_instance); | 1451 if (IsNTPSiteInstance(parent_site_instance)) |
| 1452 return true; |
| 1453 |
| 1454 #if BUILDFLAG(ENABLE_EXTENSIONS) |
| 1455 return ChromeContentBrowserClientExtensionsPart:: |
| 1456 ShouldFrameShareParentSiteInstanceDespiteTopDocumentIsolation( |
| 1457 url, parent_site_instance); |
| 1458 #else |
| 1459 return false; |
| 1460 #endif |
| 1452 } | 1461 } |
| 1453 | 1462 |
| 1454 bool ChromeContentBrowserClient::IsSuitableHost( | 1463 bool ChromeContentBrowserClient::IsSuitableHost( |
| 1455 content::RenderProcessHost* process_host, | 1464 content::RenderProcessHost* process_host, |
| 1456 const GURL& site_url) { | 1465 const GURL& site_url) { |
| 1457 Profile* profile = | 1466 Profile* profile = |
| 1458 Profile::FromBrowserContext(process_host->GetBrowserContext()); | 1467 Profile::FromBrowserContext(process_host->GetBrowserContext()); |
| 1459 // This may be NULL during tests. In that case, just assume any site can | 1468 // This may be NULL during tests. In that case, just assume any site can |
| 1460 // share any host. | 1469 // share any host. |
| 1461 if (!profile) | 1470 if (!profile) |
| (...skipping 2153 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3615 RedirectNonUINonIOBrowserThreadsToTaskScheduler() { | 3624 RedirectNonUINonIOBrowserThreadsToTaskScheduler() { |
| 3616 return variations::GetVariationParamValue( | 3625 return variations::GetVariationParamValue( |
| 3617 "BrowserScheduler", "RedirectNonUINonIOBrowserThreads") == "true"; | 3626 "BrowserScheduler", "RedirectNonUINonIOBrowserThreads") == "true"; |
| 3618 } | 3627 } |
| 3619 | 3628 |
| 3620 // static | 3629 // static |
| 3621 void ChromeContentBrowserClient::SetDefaultQuotaSettingsForTesting( | 3630 void ChromeContentBrowserClient::SetDefaultQuotaSettingsForTesting( |
| 3622 const storage::QuotaSettings* settings) { | 3631 const storage::QuotaSettings* settings) { |
| 3623 g_default_quota_settings = settings; | 3632 g_default_quota_settings = settings; |
| 3624 } | 3633 } |
| OLD | NEW |